Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/moses-smt/vowpal_wabbit.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Langford <jl@hunch.net>2013-11-27 20:46:15 +0400
committerJohn Langford <jl@hunch.net>2013-11-27 20:46:15 +0400
commit48b02ef1c13d5da3721b89cec8433d5e81d8cf37 (patch)
treed766d7a4c0d66e6a8d56c62d95ca8ca71e504684 /vowpalwabbit/parse_primitives.h
parent498dcab1d21b70ead8989904a08d1a7e83c53697 (diff)
fixed parser segfault
Diffstat (limited to 'vowpalwabbit/parse_primitives.h')
-rw-r--r--vowpalwabbit/parse_primitives.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/vowpalwabbit/parse_primitives.h b/vowpalwabbit/parse_primitives.h
index 4d1a6ce9..ddbcfe04 100644
--- a/vowpalwabbit/parse_primitives.h
+++ b/vowpalwabbit/parse_primitives.h
@@ -145,7 +145,10 @@ inline float parseFloat(char * p, char **end)
char* start = p;
if (!*p)
- return 0;
+ {
+ *end = p;
+ return 0;
+ }
int s = 1;
while (*p == ' ') p++;