gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] [taler-twister] branch master updated: indentation


From: gnunet
Subject: [GNUnet-SVN] [taler-twister] branch master updated: indentation
Date: Fri, 11 Oct 2019 23:49:38 +0200

This is an automated email from the git hooks/post-receive script.

grothoff pushed a commit to branch master
in repository twister.

The following commit(s) were added to refs/heads/master by this push:
     new d804a0c  indentation
d804a0c is described below

commit d804a0c8a705ad0ec1f8eacbba4ff847b2e7e8f7
Author: Christian Grothoff <address@hidden>
AuthorDate: Fri Oct 11 23:49:36 2019 +0200

    indentation
---
 src/twister/taler-twister-service.c | 28 ++++++++++------------------
 1 file changed, 10 insertions(+), 18 deletions(-)

diff --git a/src/twister/taler-twister-service.c 
b/src/twister/taler-twister-service.c
index 51173a3..06676e8 100644
--- a/src/twister/taler-twister-service.c
+++ b/src/twister/taler-twister-service.c
@@ -316,51 +316,51 @@ static unsigned int hack_response_code;
  * Will point to a JSON object to delete.  Only cares about
  * _download_ objects.
  */
-static char *delete_path = NULL;
+static char *delete_path;
 
 /**
  * Will point to a JSON _string_ object
  * which will get a character flipped.
  * Only checked against _download_ objects.
  */
-static char *flip_path_dl = NULL;
+static char *flip_path_dl;
 
 /**
  * Will point to a JSON _string_ object
  * which will get a character flipped.
  * Only checked against _upload_ objects.
  */
-static char *flip_path_ul = NULL;
+static char *flip_path_ul;
 
 /**
  * Will point to a JSON object to modify.
  * Only checked against _download_ objects.
  */
-static char *modify_path_dl = NULL;
+static char *modify_path_dl;
 
 /**
  * Will point to a JSON object to modify.
  * Only checked against _upload_ objects.
  */
-static char *modify_path_ul = NULL;
+static char *modify_path_ul;
 
 /**
  * If true, will randomly truncate the request body
  * to upload to the proxied service.
  */
-static unsigned int malform_upload = GNUNET_NO;
+static unsigned int malform_upload;
 
 /**
  * If true, will randomly truncate the response body
  * before returning to the client.
  */
-static unsigned int malform = GNUNET_NO;
+static unsigned int malform;
 
 /**
  * New value to give the modified field.
  * Both for upload and download mods.
  */
-static char *modify_value = NULL;
+static char *modify_value;
 
 /**
  * Size of the malformed body to be uploaded to the
@@ -925,7 +925,6 @@ con_val_iter (void *cls,
   char *new_value = NULL;
 
   (void) kind;
-
   if (0 == strcmp (MHD_HTTP_HEADER_HOST,
                    key))
   {
@@ -989,7 +988,6 @@ walk_object (const char *path,
              char **target,
              json_t *json)
 {
-
   json_t *element;
   json_t *cur;
   char *token;
@@ -1004,7 +1002,6 @@ walk_object (const char *path,
   last_token = strrchr (path_dup, '.') + 1;
   /* Give first nondelim char. */
   token = strtok (path_dup, ".");
-
   if (NULL == (element = json))
   {
     TALER_LOG_ERROR ("Attempting to walk a non JSON response!\n");
@@ -1018,7 +1015,6 @@ walk_object (const char *path,
                      last_token, last_token);
     if (NULL == token)
       return GNUNET_SYSERR; // path was ".", refuse to process it.
-
     if (NULL != (cur = json_object_get (element,
                                         token)))
     {
@@ -1026,7 +1022,6 @@ walk_object (const char *path,
       token = strtok (NULL, ".");
       continue;
     }
-
     if (NULL != (cur = json_array_get (element,
                                        (unsigned int) strtoul
                                          (token, NULL, 10))))
@@ -1038,7 +1033,6 @@ walk_object (const char *path,
     TALER_LOG_WARNING ("Path token '%s' not found\n",
                        token);
     GNUNET_free (path_dup);
-
     return GNUNET_NO;
   }
 
@@ -1061,7 +1055,6 @@ walk_object (const char *path,
   *target = GNUNET_strdup (last_token);
   *parent = element;
   GNUNET_free (path_dup);
-
   return GNUNET_OK;
 }
 
@@ -1121,13 +1114,12 @@ modify_object (struct MHD_Connection *con,
     goto perform_modbody;
   }
 
-  TALER_LOG_ERROR ("Unvalid new value given: %s\n",
+  TALER_LOG_ERROR ("Invalid new value given: %s\n",
                    modify_value);
   GNUNET_free (target);
-  json_decref (new_value);
   return GNUNET_SYSERR;
 
-  perform_modbody:
+perform_modbody:
   ret_modify = -1;
   if (json_is_object (parent))
     ret_modify = json_object_set (parent,

-- 
To stop receiving notification emails like this one, please contact
address@hidden.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]