commit 28a4b9e407ea412c4a00b1856c12e0db15a6f068
parent de5de7f85d99550019fe8137cd8a23446f8f31ce
Author: Marcello Stanisci <stanisci.m@gmail.com>
Date: Fri, 14 Jun 2019 14:47:03 +0200
fix segfault
Diffstat:
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/twister/taler-twister-service.c b/src/twister/taler-twister-service.c
@@ -322,14 +322,14 @@ static char delete_path[TWISTER_PATH_LENGTH] = {'\0'};
* which will get a character flipped.
* Only checked against _download_ objects.
*/
-static char flip_path_dl[TWISTER_PATH_LENGTH] = {'\0'};
+static char *flip_path_dl = NULL;
/**
* Will point to a JSON _string_ object
* which will get a character flipped.
* Only checked against _upload_ objects.
*/
-static char flip_path_ul[TWISTER_PATH_LENGTH] = {'\0'};
+static char *flip_path_ul = NULL;
/**
* Will point to a JSON object to modify.
@@ -1564,7 +1564,7 @@ create_response (void *cls,
malform_upload = GNUNET_NO;
}
- if ('\0' != flip_path_ul[0])
+ if (NULL != flip_path_ul)
{
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Will try to flip: %s\n",
@@ -1797,7 +1797,7 @@ create_response (void *cls,
hack_response_code = 0; /* reset for next request */
}
- if ('\0' != flip_path_dl[0])
+ if (NULL != flip_path_dl)
{
TALER_LOG_DEBUG ("Will flip path: %s\n",
flip_path_dl);
@@ -2639,7 +2639,7 @@ handle_flip_path_ul (void *cls,
(tailsize == GNUNET_STRINGS_buffer_tokenize ((char *) &src[1],
tailsize,
1,
- &flip_path_dl));
+ &flip_path_ul));
send_acknowledgement (c);
}