Skip to content

Commit

Permalink
Fix missing null check in netio_bridge_save_config.
Browse files Browse the repository at this point in the history
Fixes #245
  • Loading branch information
flaviojs committed Oct 6, 2024
1 parent d0bc918 commit 5741d72
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion common/net_io_bridge.c
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,8 @@ void netio_bridge_save_config(netio_bridge_t *t,FILE *fd)
fprintf(fd,"nio_bridge create %s\n",t->name);

for(i=0;i<NETIO_BRIDGE_MAX_NIO;i++)
fprintf(fd,"nio_bridge add_nio %s %s\n",t->name,t->nio[i]->name);
if(t->nio[i])
fprintf(fd,"nio_bridge add_nio %s %s\n",t->name,t->nio[i]->name);

fprintf(fd,"\n");
}
Expand Down

0 comments on commit 5741d72

Please sign in to comment.