Skip to content

Commit

Permalink
Assignments embedded in if-condition are not a good idea.
Browse files Browse the repository at this point in the history
  • Loading branch information
nbriggs committed Nov 13, 2023
1 parent 6cea8c6 commit 4247731
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/dir.c
Original file line number Diff line number Diff line change
Expand Up @@ -2150,7 +2150,8 @@ LispPTR COM_next_file(LispPTR *args)
propp = gfsp->propp;

dfp = &FinfoArray[finfoid];
if (dfp->head == (FINFO *)0 || (fp = dfp->next) == (FINFO *)0) return (SMALLP_MINUSONE);
fp = dfp->next;
if (dfp->head == NULL || fp == NULL) return (SMALLP_MINUSONE);
dfp->next = fp->next;

laddr = gfsp->name;
Expand Down

0 comments on commit 4247731

Please sign in to comment.