Skip to content

Commit

Permalink
all: fix clean_path()
Browse files Browse the repository at this point in the history
GCC 13 identified a bug in clean_path where the source of a strcpy()
was always NULL.

Signed-off-by: Quentin Armitage <[email protected]>
  • Loading branch information
pqarmitage committed Apr 1, 2024
1 parent 4dda7c7 commit 699bc10
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/notify.c
Original file line number Diff line number Diff line change
Expand Up @@ -712,7 +712,7 @@ clean_path(const char *old_argv)

slash = strchr(ip, '/');
if (!slash)
strcpy(op, slash);
strcpy(op, ip);
else if (slash > ip) {
strncpy(op, ip, slash - ip);
op += slash - ip;
Expand Down

0 comments on commit 699bc10

Please sign in to comment.