Skip to content

Commit

Permalink
modpost: explain why we can't use strsep
Browse files Browse the repository at this point in the history
Mention why we open-code strsep, so it is clear that it is intentional.

Fixes: 736bb11 ("modpost: remove use of non-standard strsep() in HOSTCC code")
Signed-off-by: Wolfram Sang <[email protected]>
Signed-off-by: Masahiro Yamada <[email protected]>
  • Loading branch information
wsakernel authored and masahir0y committed Jul 27, 2020
1 parent 92ed301 commit 6020db5
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions scripts/mod/modpost.c
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,7 @@ char *get_line(char **stringp)
if (!orig || *orig == '\0')
return NULL;

/* don't use strsep here, it is not available everywhere */
next = strchr(orig, '\n');
if (next)
*next++ = '\0';
Expand Down

0 comments on commit 6020db5

Please sign in to comment.