mirror of
https://github.com/cookiengineer/audacity
synced 2026-01-09 14:17:10 +01:00
Fix another bug reported by Wipro: "...at line 89 in function xlungetc , file xlio.c
'fptr', can take a NULL value. It is being derefed directly or through its aliases at: '(((fptr- >n_info).n_xstream).xs_savech)'"
This commit is contained in:
@@ -72,7 +72,7 @@ void xlungetc(LVAL fptr, int ch)
|
|||||||
|
|
||||||
/* check for ungetc from nil */
|
/* check for ungetc from nil */
|
||||||
if (fptr == NIL)
|
if (fptr == NIL)
|
||||||
;
|
; //ANSWER-ME: Return? "else if"?
|
||||||
|
|
||||||
/* otherwise, check for ungetc to a stream */
|
/* otherwise, check for ungetc to a stream */
|
||||||
if (ustreamp(fptr)) {
|
if (ustreamp(fptr)) {
|
||||||
@@ -85,7 +85,7 @@ void xlungetc(LVAL fptr, int ch)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* otherwise, it must be a file */
|
/* otherwise, it must be a file */
|
||||||
else
|
else if (fptr)
|
||||||
setsavech(fptr,ch);
|
setsavech(fptr,ch);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user