Changeset 25014 in vbox for trunk/src/VBox/Runtime/common/string
- Timestamp:
- Nov 26, 2009 3:26:36 PM (15 years ago)
- svn:sync-xref-src-repo-rev:
- 55327
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/common/string/strversion.cpp
r25005 r25014 111 111 * Do a parallel parse of the strings. 112 112 */ 113 int iRes = 0;114 113 while (*pszVer1 || *pszVer2) 115 114 { … … 127 126 { 128 127 if (uVal1 != uVal2) 129 { 130 iRes = uVal1 > uVal2 ? 1 : 2; 131 break; 132 } 128 return uVal1 < uVal2 ? -1 : 1; 133 129 } 134 130 else if ( !fNumeric1 && fNumeric2 && uVal2 == 0 && cchBlock1 == 0 … … 144 140 iDiff = cchBlock1 < cchBlock2 ? -1 : 1; 145 141 if (iDiff) 146 { 147 iRes = iDiff > 0 ? 1 : 2; 148 break; 149 } 142 return iDiff < 0 ? -1 : 1; 150 143 } 151 144 } 152 return iRes;145 return 0; 153 146 } 154 147 RT_EXPORT_SYMBOL(RTStrVersionCompare);
Note:
See TracChangeset
for help on using the changeset viewer.