: nply/fiche2

commit 7575609c415f84320b7956279d4d2adef8a5228e
parent 319bd7327382ef9d21d1ff3d0a5be5ac4fed5a48
Author: solusipse <solus1ps3@gmail.com>
Date: Sat, 2 Sep 2017 19:44:08 +0200

Fixed null dereference, renamed argument to match declaration
1 file changed, 1 insertion(+), 2 deletions(-)
M
fiche.c
|
3
+--
diff --git a/fiche.c b/fiche.c
@@ -141,7 +141,7 @@ static int create_directory(char *output_dir, char *slug);
  * @arg data Buffer with data received from the user
  * @arg path Path at which file containing data from the buffer will be created
  */
-static int save_to_file(uint8_t *data, char *output_dir, char *path);
+static int save_to_file(uint8_t *data, char *output_dir, char *slug);
 
 
 // Logging-related

@@ -626,7 +626,6 @@ static void *handle_connection(void *args) {
 
         // Cleanup
         free(c);
-        free(slug);
         pthread_exit(NULL);
         return NULL;
     }