[Marble-bugs] [Bug 298502] New: infinite loop in MercatorProjection.cpp
Sune Vuorela
debian at pusling.com
Fri Apr 20 19:16:39 UTC 2012
https://bugs.kde.org/show_bug.cgi?id=298502
Bug ID: 298502
Severity: normal
Version: unspecified
Priority: NOR
Assignee: marble-bugs at kde.org
Summary: infinite loop in MercatorProjection.cpp
Classification: Unclassified
OS: Linux
Reporter: debian at pusling.com
Hardware: Debian unstable
Status: NEW
Component: general
Product: marble
in a custom app built on libmarble, I've hit a infiinte loop in
MercatorProjection.cpp
Reproducible: Sometimes
Steps to Reproduce:
build a my secret app and run it
Actual Results:
infinite loop in ~75% of the cases
Expected Results:
no infinite loop
in MercatorProjection.cpp in the function
231 bool MercatorProjection::geoCoordinates( const int x, const int y,
236 const int radius = viewport->radius(); // can be null in our case
244 const qreal pixel2Rad = M_PI / (2 * radius); // pixel2Rad is now
infinity
249 lon = xPixels * pixel2Rad + centerLon; // lon is now infinity
251 while ( lon > M_PI ) lon -= 2*M_PI; // inf-=2*M_PI is still inf
and > M_PI
loops forever there.
line numbers is based on current HEAD which is v4.7.95-484-ga4626c0
bug observed with marble 4.7.4 but code looks still the same
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the Marble-bugs
mailing list