Changeset 11482


Ignore:
Timestamp:
07/20/11 08:04:13 (13 years ago)
Author:
tbretz
Message:
Fixed a problem with stoi when the string was empty.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/FACT++/src/Converter.cc

    r11479 r11482  
    775775        const string n = what[3]; // counter
    776776
    777         const int cnt = stoi(n);
     777        const int cnt = n.empty() ? 0 : stoi(n);
    778778
    779779        // if the :N part was not given assume 1
Note: See TracChangeset for help on using the changeset viewer.