X-Git-Url: https://git.zerfleddert.de/cgi-bin/gitweb.cgi/proxmark3-svn/blobdiff_plain/3f5bcc3b927e4a132e9e87b864ba7342c4423b37..06d09c98eb9aff8fc1f258f60eb869728ebb92a8:/client/util.c?ds=sidebyside diff --git a/client/util.c b/client/util.c index b2ac82ae..a6ba8e81 100644 --- a/client/util.c +++ b/client/util.c @@ -63,7 +63,10 @@ void AddLogLine(char *file, char *extData, char *c) { fprintf(f, "%s", extData); fprintf(f, "%s\n", c); fflush(f); - fclose(f); + if (f) { + fclose(f); + f = NULL; + } } void AddLogHex(char *fileName, char *extData, const uint8_t * data, const size_t len){ @@ -280,7 +283,6 @@ int param_getptr(const char *line, int *bg, int *en, int paramnum) return 0; } - char param_getchar(const char *line, int paramnum) { int bg, en;