Fixed the strcmp comparison and printing error in the exclude_interface function.

This commit is contained in:
MissValeska 2014-10-28 16:39:08 -07:00
parent 84b6ed71d5
commit 2cc1ce7892

View File

@ -371,9 +371,9 @@ exclude_interface(void)
printf("Interface names in Use: %s", (char *) server_opt.ifs);
for (i = 0; i < me.cur_ifs_n; i++) {
if (strcmp(me.cur_ifs[i], optarg) == 0) {
if (strcmp(me.cur_ifs[i].dev_name, optarg) == 0) {
printf("Interface %s removed, And replaced with %s",
me.cur_ifs[i], me.cur_ifs[me.cur_ifs_n]);
me.cur_ifs[i].dev_name, me.cur_ifs[me.cur_ifs_n].dev_name);
ifs_del(me.cur_ifs, &me.cur_ifs_n, i);
return 0;
}