diff options
author | Joseph Hunkeler <jhunkeler@gmail.com> | 2010-12-05 15:20:54 -0500 |
---|---|---|
committer | Joseph Hunkeler <jhunkeler@gmail.com> | 2010-12-05 15:20:54 -0500 |
commit | cc899c2ebd52e3f78471f3df6622a5fcb026fe17 (patch) | |
tree | e52ef0be1d8b0a2f8611031b392337b99dfc1940 /src/nukectl.c | |
parent | 2fb784d8ce44979afcb4c7a9b4cc7f17be1c3ba1 (diff) | |
download | NetNuke2-cc899c2ebd52e3f78471f3df6622a5fcb026fe17.tar.gz |
Added ignore_device function
Diffstat (limited to 'src/nukectl.c')
-rw-r--r-- | src/nukectl.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/nukectl.c b/src/nukectl.c index 22e628e..8b8c7ff 100644 --- a/src/nukectl.c +++ b/src/nukectl.c @@ -35,6 +35,25 @@ extern int safety_flag; extern pthread_mutex_t lock_global; extern pthread_mutex_t lock_write; +void ignore_device(char** list, nndevice_t** d) +{ + int i = 0; + int j = 0; + + for( i = 0 ; d[i] != NULL ; i++ ) + { + for( j = 0 ; list[j] != NULL ; j++ ) + { + if(!strncasecmp(d[i]->path, list[j], strlen(list[j]))) + { + COM(self, "%s\n", list[j]); + memset(d[i], 0, sizeof(nndevice_t)); + //memmove(d[end-1], d[i], sizeof(nndevice_t)); + } + } + } +} + void* wipe(void* device) { nndevice_t* d = (nndevice_t*)device; |