]> git.mxchange.org Git - flightgear.git/blobdiff - src/GUI/AirportList.cxx
Boris Koenig:
[flightgear.git] / src / GUI / AirportList.cxx
index 6e4570b6c9236dd0def5c0c7585791245a871fc3..df7c043d3e2883a8f5d33f4b4aeb67ee50f8db45 100644 (file)
@@ -16,7 +16,7 @@ AirportList::AirportList (int x, int y, int width, int height)
 
     _content = new char *[_nAirports+1];
     for (int i = 0; i < _nAirports; i++) {
-        const FGAirport * airport = _airports->getAirport(i);
+        const FGAirport *airport = _airports->getAirport(i);
         snprintf(buf, 1023, "%s  %s\0",
                  airport->id.c_str(),
                  airport->name.c_str());
@@ -25,7 +25,7 @@ AirportList::AirportList (int x, int y, int width, int height)
         
         _content[i] = new char[buf_len+1];
         memcpy(_content[i], buf, buf_len);
-        _content[i][buf_len+1] = '\0';
+        _content[i][buf_len] = '\0';
     }
     _content[_nAirports] = 0;
     newList(_content);