]> git.mxchange.org Git - flightgear.git/blobdiff - src/Instrumentation/dclgps.cxx
fix a typo
[flightgear.git] / src / Instrumentation / dclgps.cxx
index 3156c55ac531f6cfd58e40898dd2d80a33963aee..9d6ccc67575c00232718435535497ecb28e7383a 100644 (file)
@@ -257,9 +257,8 @@ void GPSPage::OBSPressed() {}
 void GPSPage::MsgPressed() {}
 
 string GPSPage::GPSitoa(int n) {
-       char buf[4];
-       // TODO - sanity check n!
-       sprintf(buf, "%i", n);
+       char buf[6];
+       snprintf(buf, 6, "%i", n);
        string s = buf;
        return(s);
 }