Opened 10 years ago

Last modified 7 years ago

#1173 closed defect (Fixed)

crypto.c:613: error: comparison of unsigned expression >= 0 is always true

Reported by: arma Owned by:
Priority: Low Milestone:
Component: Core Tor/Tor Version: 0.2.2.6-alpha
Severity: Keywords:
Cc: arma, nickm, Sebastian, edmanm Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

https://buildbot.vidalia-project.net/builders/kore.fc12.tor-master/builds/0/steps/compile/logs/stdio

gcc -DHAVE_CONFIG_H -I. -I../.. -I../../src/common -g -O2 -Wall -g -O2 -fno-strict-aliasing -W -Wfloat-equal -Wundef -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes -Wwrite-strings -Wredundant-decls -Wchar-subscripts -Wcomment -Wformat=2 -Wwrite-strings -Wmissing-declarations -Wredundant-decls -Wnested-externs -Wbad-function-cast -Wswitch-enum -Werror -Winit-self -Wmissing-field-initializers -Wdeclaration-after-statement -Wold-style-definition -Waddress -Wmissing-noreturn -Wnormalized=id -Woverride-init -Wstrict-overflow=1 -Wextra -Warray-bounds -MT crypto.o -MD -MP -MF .deps/crypto.Tpo -c -o crypto.o crypto.c
cc1: warnings being treated as errors
crypto.c: In function ‘crypto_pk_write_key_to_string_impl’:
crypto.c:613: error: comparison of unsigned expression >= 0 is always true
make[3]: * [crypto.o] Error 1

Line is

tor_assert(buf->length >= 0);

where buf is

BUF_MEM *buf;

I bet fc12's openssl has a different BUF_MEM.

edmanm> [edmanm@kore ~]$ openssl version
edmanm> OpenSSL 1.0.0-fips-beta4 10 Nov 2009

Sebastian> the line hasn't been changed since r2461

Nick, any opinions?

[Automatically added by flyspray2trac: Operating System: All]

Child Tickets

Change History (4)

comment:1 Changed 10 years ago by arma

probably the best fix is to just delete the assert line -- in tor stable too.

comment:2 Changed 10 years ago by nickm

Agreed: applied to 0.2.1.x and 0.2.2.x.

comment:3 Changed 10 years ago by nickm

flyspray2trac: bug closed.

comment:4 Changed 7 years ago by nickm

Component: Tor ClientTor
Note: See TracTickets for help on using tickets.