X-Git-Url: http://git.eversberg.eu/gitweb.cgi?p=lcr.git;a=blobdiff_plain;f=lcradmin.c;h=2483a9bc42977c7d7fe40d9ef609b97b85c60f2a;hp=222700b5ce98aca380834c00da6d27dcba98bc44;hb=5f685ed847af5a80f647383d0c450b67acce17a4;hpb=323cbc387b1a068f8e2bcfd1034666406ba18c93 diff --git a/lcradmin.c b/lcradmin.c index 222700b..2483a9b 100644 --- a/lcradmin.c +++ b/lcradmin.c @@ -25,6 +25,7 @@ #include "macro.h" #include "options.h" #include "join.h" +#include "select.h" #include "joinpbx.h" #include "extension.h" #include "message.h" @@ -1300,6 +1301,8 @@ const char *admin_portinfo(int sock, int argc, char *argv[]) else printf("\t status = unblocked\n"); printf("\t mode = %s %s%s%s\n", (m[i].u.i.ntmode)?"NT-mode":"TE-mode", (m[i].u.i.ptp)?"ptp":"ptmp", (m[i].u.i.l1hold)?" l1hold":"", (m[i].u.i.l2hold)?" l2hold":""); + printf("\t out-channel = %s\n", m[i].u.i.out_channel); + printf("\t in-channel = %s\n", m[i].u.i.in_channel); if (m[i].u.i.l1link < 0) printf("\t l1 link = unknown\n"); else @@ -1578,7 +1581,11 @@ next: goto next; case ADMIN_CALL_NOTIFY: - printf("NOTIFY\n notify=%d\n number=%s\n", msg.u.call.notify, msg.u.call.callerid); fflush(stdout); + printf("NOTIFY\n notify=%d\n number=%s\n", msg.u.call.notify_progress, msg.u.call.callerid); fflush(stdout); + goto next; + + case ADMIN_CALL_PROGRESS: + printf("PROGRESS\n progress=%d\n location=%d\n", msg.u.call.notify_progress, msg.u.call.location); fflush(stdout); goto next; case ADMIN_CALL_DISCONNECT: @@ -1679,7 +1686,7 @@ int main(int argc, char *argv[]) int sock, conn; struct sockaddr_un sock_address; const char *ret = "invalid mode"; - + char options_error[256]; /* show options */ if (argc <= 1) { @@ -1755,7 +1762,7 @@ int main(int argc, char *argv[]) goto usage; } - if (read_options() == 0) { + if (read_options(options_error) == 0) { exit(EXIT_FAILURE); }