Re: [pacman-dev] [PATCH 1/3] Make alpm_graph state signedness explicit

2016-01-03 Thread Allan McRae
On 31/12/15 23:19, Rikard Falkeborn wrote: > The signedness of char is implementation defined. Since the > alpm_graph state is clearly meant to be signed, make the > signedness explicit. > > This fixes bugs on systems where char is unsigned, in comparissons > of the following type: > >

[pacman-dev] [PATCH 1/3] Make alpm_graph state signedness explicit

2015-12-31 Thread Rikard Falkeborn
The signedness of char is implementation defined. Since the alpm_graph state is clearly meant to be signed, make the signedness explicit. This fixes bugs on systems where char is unsigned, in comparissons of the following type: if(v.state == -1) which, if state is unsigned, will never be true