Skip to content

Commit

Permalink
editor: #undef O after use
Browse files Browse the repository at this point in the history
  • Loading branch information
neuschaefer committed Jan 13, 2011
1 parent b4645f7 commit 522f11a
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions editor.c
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,8 @@ void draw_scene(void)
struct it * find_object(void)
{
struct object_list *p;
#define O p->next->member

#define O p->next->member
for(p=&objects;p->next;p=p->next)
{
if (
Expand All @@ -191,6 +191,8 @@ struct it * find_object(void)
)
return &(p->next->member);
}
#undef O

return 0;
}

Expand Down Expand Up @@ -290,7 +292,6 @@ void save_data(void)
}

#define O p->next->member

for(p=&objects;p->next;p=p->next)
{
snprintf(txt,sizeof(txt),"%s %c %d %d\n",sprite_names[O.sprite],O.type,O.x,O.y);
Expand All @@ -309,6 +310,8 @@ void save_data(void)
break;
}
}
#undef O

fclose(data);
fclose(dynamic);
}
Expand Down

0 comments on commit 522f11a

Please sign in to comment.