--- embedtools/src/dwds.c 2010/10/27 16:39:47 1.1.2.6 +++ embedtools/src/dwds.c 2010/10/27 16:45:35 1.1.2.7 @@ -101,7 +101,7 @@ main(int argc, char **argv) return 1; } - if (fg) + if (!fg) switch (fork()) { case -1: printf("Error:: when fork() #%d - %s\n", errno, strerror(errno)); @@ -134,8 +134,10 @@ main(int argc, char **argv) goto end; } - if (!(wds = wifi_buildWDS(s, ifs, nif))) + if (!(wds = wifi_buildWDS(s, ifs, nif))) { + syslog(LOG_ERR, "Error:: Go to dead ...\n"); goto end; + } while (!Kill) { len = read(s, (void*) msg, sizeof msg);