Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
DISCONTINUED:openSUSE:11.2
filezilla
filezilla-int_overflow.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File filezilla-int_overflow.patch of Package filezilla
--- src/engine/transfersocket.cpp +++ src/engine/transfersocket.cpp @@ -523,7 +523,7 @@ if (start < low || start > high) { srand( (unsigned)time( NULL ) ); - start = rand() * (high - low) / (RAND_MAX + 1) + low; + start = rand() * (high - low) / (RAND_MAX < INT_MAX ? RAND_MAX + 1 : RAND_MAX) + low; } for (int i = start; i <= high; i++) --- src/interface/netconfwizard.cpp +++ src/interface/netconfwizard.cpp @@ -864,7 +864,7 @@ XRCCTRL(*this, "ID_ACTIVE_PORTMIN", wxTextCtrl)->GetValue().ToLong(&low); XRCCTRL(*this, "ID_ACTIVE_PORTMAX", wxTextCtrl)->GetValue().ToLong(&high); - int mid = (rand() * (high - low)) / (RAND_MAX + 1) + low; + int mid = (rand() * (high - low)) / (RAND_MAX < INT_MAX ? RAND_MAX + 1 : RAND_MAX) + low; for (int port = mid; port <= high; port++) if (CreateListenSocket(port)) return port;
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor