Skip to content

Commit 4beb680

Browse files
authored
Merge pull request #3549 from masatake/dont-chectk-rvalue-from-vstringnew
main: don't do NULL check for values returned from vStringNew (sort.c)
2 parents 72847ce + 085d4de commit 4beb680

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

main/sort.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,11 +92,11 @@ extern void externalSortTags (const bool toStdout, MIO *tagFile)
9292
PE_CONST char *const sortOrder1 = "LC_COLLATE=C";
9393
PE_CONST char *const sortOrder2 = "LC_ALL=C";
9494
# endif
95-
vString *cmd = vStringNew ();
9695
int ret = -1;
9796

98-
if (cmd != NULL)
9997
{
98+
vString *cmd = vStringNew ();
99+
100100
/* Ensure ASCII value sort order.
101101
*/
102102
#if defined (HAVE_SETENV) || defined (HAVE_PUTENV)

0 commit comments

Comments
 (0)