move the stat check to the stream open function
[project/uci.git] / util.c
diff --git a/util.c b/util.c
index ddb1331..28cc5df 100644 (file)
--- a/util.c
+++ b/util.c
@@ -97,6 +97,7 @@ lastval:
                last++;
                if (!*last)
                        goto error;
+               *value = last;
        }
 
        if (*section && !uci_validate_name(*section))