Created
July 2, 2014 11:11
-
-
Save naszar/60207b603bf66d699203 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/options.c b/src/options.c | |
index d81d8fb..dcc085c 100644 | |
--- a/src/options.c | |
+++ b/src/options.c | |
@@ -331,9 +331,8 @@ int opt_parse_map(char *map){ | |
} | |
currstr=map; | |
for( i=0; i<cnt; ++i ){ | |
- currsep=strchr(currstr,','); | |
currend=strchr(currstr,';'); | |
- curr_map[i].elev=atof(currstr); | |
+ curr_map[i].elev=strtof(currstr, &currsep); | |
curr_map[i].temp=atof(++currsep); | |
if( curr_map[i].elev > prevelev ){ | |
free(curr_map); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment