Ticket #50 (new task)

Opened 21 months ago

Suspicious warnings when building for x86-64

Reported by: belegdol Owned by: daelstorm
Priority: major Milestone:
Component: museek_general Version: 0.1.12
Keywords: Cc:

Description

I have submitted museek+ into Fedora Extras, users will be able to install it with yum install museek+ soonish. During the review process, the reviewer reported that building for x86-64 generates the following warnings:

./Muhelp/string_ext.hh:61: warning: comparison is always true due to limited range of data type ./Muhelp/string_ext.hh:64: warning: comparison is always false due to limited range of data type ./Muhelp/string_ext.hh:79: warning: comparison is always true due to limited range of data type ./Muhelp/string_ext.hh:82: warning: comparison is always false due to limited range of data type ./Muhelp/string_ext.hh:97: warning: comparison is always true due to limited range of data type ./Muhelp/string_ext.hh:100: warning: comparison is always false due to limited range of data type ./Muhelp/string_ext.hh:114: warning: comparison is always true due to limited range of data type ./Muhelp/string_ext.hh:117: warning: comparison is always false due to limited range of data type

He said that they look suspicious. Could you please have a look?

Attachments

museek+-r744-muhelp-x86_64.patch (1.0 kB) - added by cooldwind@… 2 months ago.
std::string::npos is size_t, which is bigger than int in x86_64. Using size_t where appropiate.
museek+-r744-muhelp-x86_64.2.patch (1.0 kB) - added by cooldwind@… 2 months ago.
Correct more variables which I missed in the previous patch.

Change History

Changed 2 months ago by cooldwind@…

std::string::npos is size_t, which is bigger than int in x86_64. Using size_t where appropiate.

Changed 2 months ago by cooldwind@…

Correct more variables which I missed in the previous patch.

Add/Change #50 (Suspicious warnings when building for x86-64)

Author



Action
as new
 
Note: See TracTickets for help on using tickets.