Skip to content
Browse files

Fix wrong usage of std::string::find

  • Loading branch information...
1 parent e758e8d commit 139800bf5d030769911099a705c53c1aa44ac6d1 @syntheticpp syntheticpp committed Feb 21, 2013
Showing with 2 additions and 1 deletion.
  1. +2 −1 src/version.cc
View
3 src/version.cc
@@ -26,7 +26,7 @@ void ParseVersion(const string& version, int* major, int* minor) {
*minor = 0;
if (end != string::npos) {
size_t start = end + 1;
- end = version.find(start, '.');
+ end = version.find('.', start);
*minor = atoi(version.substr(start, end).c_str());
}
}
@@ -54,3 +54,4 @@ void CheckNinjaVersion(const string& version) {
+

0 comments on commit 139800b

Please sign in to comment.
Something went wrong with that request. Please try again.