Re: [PATCH 3rd_time] scsi: fix operator precedence warning

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



 > -		*tcp_source_port_num = (uint16_t) mbox_sts[6] >> 16;
 > +		*tcp_source_port_num = (uint16_t) (mbox_sts[6] >> 16);

I wonder why we need that cast at all?  The fact that
tcp_source_port_num is a uint16_t* should cause the value to get
truncated properly anyway.

But I agree that this patch is a minimal fix for a real bug.
-- 
Roland Dreier <rolandd@xxxxxxxxx> || For corporate legal information go to:
http://www.cisco.com/web/about/doing_business/legal/cri/index.html
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux