]> git.sur5r.net Git - ngadmin/blob - cli/com_scan.c
Code reorganized.
[ngadmin] / cli / com_scan.c
1
2 #include "common.h"
3
4
5
6
7 static bool do_scan (const struct TreeNode *tn UNUSED, int nb UNUSED, const char **com UNUSED, struct ngadmin *nga) {
8  
9  int i;
10  const struct swi_attr *sa;
11  
12  
13  if ( (i=ngadmin_scan(nga))<0 ) {
14   printErrCode(i);
15   return false;
16  }
17  
18  sa=ngadmin_getSwitchTab(nga, &nb);
19  displaySwitchTab(sa, nb);
20  
21  
22  return true;
23  
24 }
25
26
27
28 const struct TreeNode com_scan=COM("scan", do_scan, false, NULL);
29
30
31