[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-bugs] #26282 [Core Tor/Tor]: Smartlist index implicitly converted to int
#26282: Smartlist index implicitly converted to int
------------------------------+--------------------------------
Reporter: rl1987 | Owner: (none)
Type: defect | Status: new
Priority: Medium | Milestone: Tor: 0.3.5.x-final
Component: Core Tor/Tor | Version: Tor: unspecified
Severity: Normal | Keywords:
Actual Points: | Parent ID: #26196
Points: | Reviewer:
Sponsor: |
------------------------------+--------------------------------
When building with `DEBUG_SMARTLIST`:
{{{
src/common/util.c:4816:45: warning: implicit conversion loses integer
precision: 'size_t' (aka 'unsigned long') to 'int' [-Wshorten-64-to-32]
const char *s = smartlist_get(env_vars, i);
~~~~~~~~~~~~~ ^
src/common/util.c:4846:54: warning: implicit conversion loses integer
precision: 'size_t' (aka 'unsigned long') to 'int' [-Wshorten-64-to-32]
const char *s = smartlist_get(env_vars_sorted, i);
~~~~~~~~~~~~~ ^
2 warnings generated.
}}}
{{{
src/common/util.c:4816:45: warning: implicit conversion loses integer
precision: 'size_t' (aka 'unsigned long') to 'int' [-Wshorten-64-to-32]
const char *s = smartlist_get(env_vars, i);
~~~~~~~~~~~~~ ^
src/common/util.c:4846:54: warning: implicit conversion loses integer
precision: 'size_t' (aka 'unsigned long') to 'int' [-Wshorten-64-to-32]
const char *s = smartlist_get(env_vars_sorted, i);
~~~~~~~~~~~~~ ^
2 warnings generated.
}}}
{{{
src/or/control.c:4627:43: warning: implicit conversion loses integer
precision: 'size_t' (aka 'unsigned long') to 'int' [-Wshorten-64-to-32]
const char *arg = smartlist_get(args, i);
~~~~~~~~~~~~~ ^
1 warning generated.
}}}
{{{
src/or/geoip.c:153:57: warning: implicit conversion loses integer
precision: 'intptr_t' (aka 'long') to 'int' [-Wshorten-64-to-32]
geoip_country_t *c = smartlist_get(geoip_countries, idx);
~~~~~~~~~~~~~ ^~~
1 warning generated.
}}}
{{{
src/or/control.c:4627:43: warning: implicit conversion loses integer
precision: 'size_t' (aka 'unsigned long') to 'int' [-Wshorten-64-to-32]
const char *arg = smartlist_get(args, i);
~~~~~~~~~~~~~ ^
1 warning generated.
}}}
{{{
src/or/geoip.c:153:57: warning: implicit conversion loses integer
precision: 'intptr_t' (aka 'long') to 'int' [-Wshorten-64-to-32]
geoip_country_t *c = smartlist_get(geoip_countries, idx);
~~~~~~~~~~~~~ ^~~
1 warning generated.
}}}
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/26282>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs