Skip to content

Commit 5391e94

Browse files
chooglengitster
authored andcommitted
branch: remove negative exit code
Replace an instance of "exit(-1)" with "exit(1)". We don't use negative exit codes - they are misleading because Unix machines will coerce them to 8-bit unsigned values, losing the sign. Signed-off-by: Glen Choo <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent ac59c74 commit 5391e94

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

branch.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,7 @@ static void setup_tracking(const char *new_ref, const char *orig_ref,
263263
string_list_append(tracking.srcs, orig_ref);
264264
if (install_branch_config_multiple_remotes(config_flags, new_ref,
265265
tracking.remote, tracking.srcs) < 0)
266-
exit(-1);
266+
exit(1);
267267

268268
cleanup:
269269
string_list_clear(&tracking_srcs, 0);

0 commit comments

Comments
 (0)