Commit 26dc30046bbd01c7d59530d7de5695a77bf629de

Stefan Sperling 2020-02-13T10:40:47

put braces around multi-line if (...)

diff --git a/gotweb/gotweb.c b/gotweb/gotweb.c
index 8f1eb4b..f5822e1 100644
--- a/gotweb/gotweb.c
+++ b/gotweb/gotweb.c
@@ -1664,25 +1664,29 @@ gw_parse_querystring(struct gw_trans *gw_trans)
 				break;
 			}
 
- 		if ((p = gw_trans->gw_req->fieldmap[KEY_COMMIT_ID]))
+ 		if ((p = gw_trans->gw_req->fieldmap[KEY_COMMIT_ID])) {
 			if (asprintf(&gw_trans->commit, "%s",
 			    p->parsed.s) == -1)
 				return got_error_from_errno("asprintf");
+		}
 
-		if ((p = gw_trans->gw_req->fieldmap[KEY_FILE]))
+		if ((p = gw_trans->gw_req->fieldmap[KEY_FILE])) {
 			if (asprintf(&gw_trans->repo_file, "%s",
 			    p->parsed.s) == -1)
 				return got_error_from_errno("asprintf");
+		}
 
-		if ((p = gw_trans->gw_req->fieldmap[KEY_FOLDER]))
+		if ((p = gw_trans->gw_req->fieldmap[KEY_FOLDER])) {
 			if (asprintf(&gw_trans->repo_folder, "%s",
 			    p->parsed.s) == -1)
 				return got_error_from_errno("asprintf");
+		}
 
-		if ((p = gw_trans->gw_req->fieldmap[KEY_HEADREF]))
+		if ((p = gw_trans->gw_req->fieldmap[KEY_HEADREF])) {
 			if (asprintf(&gw_trans->headref, "%s",
 			    p->parsed.s) == -1)
 				return got_error_from_errno("asprintf");
+		}
 
 		if (action == NULL) {
 			error = got_error_from_errno("invalid action");