summaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
Diffstat (limited to 'core')
-rw-r--r--core/dive.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/dive.c b/core/dive.c
index 033139d0c..f37ad6272 100644
--- a/core/dive.c
+++ b/core/dive.c
@@ -3841,9 +3841,9 @@ struct picture *clone_picture(struct picture *src)
void dive_remove_picture(char *filename)
{
struct picture **picture = &current_dive->picture_list;
- while (picture && !same_string((*picture)->filename, filename))
+ while (*picture && !same_string((*picture)->filename, filename))
picture = &(*picture)->next;
- if (picture) {
+ if (*picture) {
struct picture *temp = (*picture)->next;
picture_free(*picture);
*picture = temp;