// CRC Calculations from the software reveng commands
//-----------------------------------------------------------------------------
-#include <stdlib.h>
#ifdef _WIN32
# include <io.h>
# include <fcntl.h>
#include <stdio.h>
#include <string.h>
-//#include <stdlib.h>
-//#include <ctype.h>
+#include <stdlib.h>
+#include <ctype.h>
#include "cmdmain.h"
#include "cmdcrc.h"
#include "reveng/reveng.h"
while(isspace(str[beginIndex])){
++beginIndex;
}
- if(str[beginIndex] == '\0')
+ if(str[beginIndex] == '\0') {
break;
- endIndex = beginIndex;
+ }
+ endIndex = beginIndex;
while (str[endIndex] && !isspace(str[endIndex])){
++endIndex;
}