lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20120921113745.GA21483@elgon.mountain>
Date:	Fri, 21 Sep 2012 14:37:45 +0300
From:	Dan Carpenter <dan.carpenter@...cle.com>
To:	maximlevitsky@...il.com
Cc:	linux-kernel@...r.kernel.org,
	Andrew Morton <akpm@...ux-foundation.org>
Subject: re: memstick: add support for legacy memorysticks

Hello Maxim Levitsky,

The patch d59dd7c61b24: "memstick: add support for legacy 
memorysticks" from Sep 21, 2012, leads to the following warning:
drivers/memstick/core/ms_block.c:147 sg_compare_to_buffer()
	 warn: signedness bug returning '-1'

   141  
   142          if (!retval && len)
   143                  retval = -1;
                        ^^^^^^^^^^^
   144  
   145          sg_miter_stop(&miter);
   146          local_irq_restore(flags);
   147          return retval;
   148  }

This function is bool so it always returns true if len is non-zero.

The comments at the top of the function don't talk about if a 1 means
the same and 0 means different or if it's the other way around.

regards,
dan carpenter

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ