Return NULL if file_stream is NULL
2001-08-03 Bradford Hovinen <hovinen@ximian.com> * config-log.c (load_log_entry): Return NULL if file_stream is NULL
This commit is contained in:
parent
a1c5aa388f
commit
212641565b
2 changed files with 2 additions and 1 deletions
|
@ -738,7 +738,7 @@ load_log_entry (ConfigLog *config_log,
|
|||
g_return_val_if_fail (config_log != NULL, NULL);
|
||||
g_return_val_if_fail (IS_CONFIG_LOG (config_log), NULL);
|
||||
|
||||
if (feof (config_log->p->file_stream))
|
||||
if (config_log->p->file_stream == NULL || feof (config_log->p->file_stream))
|
||||
return NULL;
|
||||
|
||||
if (fgets (buffer, 1024, config_log->p->file_stream) == NULL)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue