We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3f01a4c commit 2d89574Copy full SHA for 2d89574
include/simulation/config.hpp
@@ -52,18 +52,19 @@ struct DefaultConf
52
if (line[0] == '#') {
53
continue;
54
}
55
+ const char* line_c = line.c_str();
56
switch (line_count) {
57
case 0:
- DefaultConf<T>::WIN_WIDTH = std::atoi(line.c_str());
58
+ DefaultConf<T>::WIN_WIDTH = std::atoi(line_c);
59
break;
60
case 1:
- DefaultConf<T>::WIN_HEIGHT = std::atoi(line.c_str());
61
+ DefaultConf<T>::WIN_HEIGHT = std::atoi(line_c);
62
63
case 2:
- DefaultConf<T>::USE_FULLSCREEN = std::atoi(line.c_str());
64
+ DefaultConf<T>::USE_FULLSCREEN = std::atoi(line_c);
65
66
case 3:
- DefaultConf<T>::ANTS_COUNT = std::atoi(line.c_str());
67
+ DefaultConf<T>::ANTS_COUNT = std::atoi(line_c);
68
69
default:
70
0 commit comments