Changeset 359 for asp3_tinet_ecnl_arm/trunk/ntshell/src
- Timestamp:
- Jun 20, 2018, 7:59:22 PM (6 years ago)
- Location:
- asp3_tinet_ecnl_arm/trunk/ntshell/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
asp3_tinet_ecnl_arm/trunk/ntshell/src/fdtable.c
r352 r359 400 400 FD_SET(fd, (fd_set *)&flgptn); 401 401 } 402 if (rpor.wricnt < rpor.wbufsz) {402 if (rpor.wricnt != 0) { 403 403 if (fp->writeevt_w == fp->writeevt_r) fp->writeevt_w++; 404 404 … … 428 428 FD_SET(fd, (fd_set *)flgptn); 429 429 } 430 if (rpor.wricnt < rpor.wbufsz) {430 if (rpor.wricnt != 0) { 431 431 if (fp->writeevt_w == fp->writeevt_r) fp->writeevt_w++; 432 432 -
asp3_tinet_ecnl_arm/trunk/ntshell/src/net_misc.c
r352 r359 60 60 #include "kernel_cfg.h" 61 61 #include "tinet_cfg.h" 62 #include "util/ntstdio.h" 63 64 extern ntstdio_t ntstdio; 62 65 63 66 T_DHCP4_CLI_CONTEXT *dhcp4_cli_initialize(ID tskid, ID cepid); … … 94 97 95 98 get_tid(&nc->tskid); 96 syslog(LOG_NOTICE, "[NET MISC:%d,%d] started.", nc->tskid, (ID)exinf);99 ntstdio_printf(&ntstdio, "[NET MISC:%d,%d] started.", nc->tskid, (ID)exinf); 97 100 98 101 /* 初期化 */ … … 102 105 ret = get_tim(&time); 103 106 if (ret != E_OK) { 104 syslog(LOG_NOTICE, "[NET MISC,%d] get_tim error: %7lu,%s",107 ntstdio_printf(&ntstdio, "[NET MISC,%d] get_tim error: %7lu,%s", 105 108 nc->cepid, time / SYSTIM_HZ, itron_strerror(ret)); 106 109 return; … … 116 119 error = tslp_tsk(timer); 117 120 if ((error != E_OK) && (error != E_TMOUT)) { 118 syslog(LOG_NOTICE, "[NET MISC,%d] tslp_tsk error: %s %d",121 ntstdio_printf(&ntstdio, "[NET MISC,%d] tslp_tsk error: %s %d", 119 122 nc->cepid, itron_strerror(error), timer); 120 123 break; … … 123 126 ret = get_tim(&time); 124 127 if (ret != E_OK) { 125 syslog(LOG_NOTICE, "[NET MISC,%d] get_tim error: %s",128 ntstdio_printf(&ntstdio, "[NET MISC,%d] get_tim error: %s", 126 129 nc->cepid, itron_strerror(ret)); 127 130 break; -
asp3_tinet_ecnl_arm/trunk/ntshell/src/ntp_cli.c
r352 r359 50 50 #include <t_syslog.h> 51 51 #include "kernel_cfg.h" 52 #include "util/ntstdio.h" 53 54 extern ntstdio_t ntstdio; 52 55 53 56 #endif /* of #if defined(TARGET_KERNEL_ASP) */ … … 276 279 } 277 280 278 syslog(LOG_NOTICE, "[NTP CLI,%d] recv time: %s .%09u",281 ntstdio_printf(&ntstdio, "[NTP CLI,%d] recv time: %s .%09u\n", 279 282 nc->cepid, nc->buf, tp.tv_nsec); 280 283 } … … 308 311 line = lookup_ipaddr(&nc->ipaddr6, NTP_SRV_URL, API_PROTO_IPV4); 309 312 if (line == NULL || !in6_is_addr_ipv4mapped(&nc->ipaddr6)) { 310 syslog(LOG_NOTICE, "[NTP CLI,%d] sleep %d.%03u[s], unknown host.",313 ntstdio_printf(&ntstdio, "[NTP CLI,%d] sleep %d.%03u[s], unknown host.", 311 314 nc->cepid, SLP_ITV / SYSTIM_HZ, SLP_ITV % SYSTIM_HZ); 312 315 nc->timer = SLP_ITV; … … 316 319 #else /* of #if defined(SUPPORT_INET6) && defined(SUPPORT_INET4) */ 317 320 if ((line = lookup_ipaddr(&nc->snd_rmt.ipaddr, NTP_SRV_URL, DEFAULT_API_PROTO)) == NULL) { 318 syslog(LOG_NOTICE, "[NTP CLI,%d] sleep %d.%03u[s], unknown host.",321 ntstdio_printf(&ntstdio, "[NTP CLI,%d] sleep %d.%03u[s], unknown host.", 319 322 nc->cepid, SLP_ITV / SYSTIM_HZ, SLP_ITV % SYSTIM_HZ); 320 323 nc->timer = SLP_ITV; … … 420 423 421 424 if ((error = udp_snd_dat(nc->cepid, &nc->snd_rmt, ntp, len, TMO_NBLK)) != E_WBLK) { 422 syslog(LOG_NOTICE, "[NTP CLI,%d] udp_snd_dat error: %s",425 ntstdio_printf(&ntstdio, "[NTP CLI,%d] udp_snd_dat error: %s", 423 426 nc->cepid, itron_strerror(error)); 424 427 return error; … … 438 441 ret = get_tim(&time); 439 442 if (ret != E_OK) { 440 syslog(LOG_NOTICE, "[NTP CLI,%d] get_tim error: %s",443 ntstdio_printf(&ntstdio, "[NTP CLI,%d] get_tim error: %s", 441 444 nc->cepid, itron_strerror(ret)); 442 445 tp->tv_sec = 0; … … 458 461 ret = set_tim(time); 459 462 if (ret != E_OK) { 460 syslog(LOG_NOTICE, "[NTP CLI,%d] set_tim error: %s",463 ntstdio_printf(&ntstdio, "[NTP CLI,%d] set_tim error: %s", 461 464 nc->cepid, itron_strerror(ret)); 462 465 } … … 476 479 if (len < 0 && len != E_RLWAI) { 477 480 /* E_RLWAI 以外で、0 以下の場合は、エラーを意味している。*/ 478 syslog(LOG_NOTICE, "[NTP CLI,%d] callback error: %s, fncd: %s", nc->cepid,481 ntstdio_printf(&ntstdio, "[NTP CLI,%d] callback error: %s, fncd: %s", nc->cepid, 479 482 itron_strerror(len), in_strtfn(fncd)); 480 483 } … … 483 486 if ((len = udp_rcv_dat(nc->cepid, &nc->rcv_rmt, &nc->ntp_msg, len, TMO_POL)) < 0) 484 487 { 485 syslog(LOG_NOTICE, "[NTP CLI,%d] udp_rcv_dat error: %s", nc->cepid,488 ntstdio_printf(&ntstdio, "[NTP CLI,%d] udp_rcv_dat error: %s", nc->cepid, 486 489 itron_strerror(len)); 487 490 } … … 515 518 516 519 get_tid(&nc->tskid); 517 syslog(LOG_NOTICE, "[NTP CLI:%d,%d] started.", nc->tskid, (ID)exinf);520 ntstdio_printf(&ntstdio, "[NTP CLI:%d,%d] started.", nc->tskid, (ID)exinf); 518 521 519 522 /* 初期化 */ … … 522 525 ret = get_tim(&time); 523 526 if (ret != E_OK) { 524 syslog(LOG_NOTICE, "[NTP CLI,%d] get_tim error: %7lu,%s",527 ntstdio_printf(&ntstdio, "[NTP CLI,%d] get_tim error: %7lu,%s", 525 528 nc->cepid, time / SYSTIM_HZ, itron_strerror(ret)); 526 529 return; … … 536 539 error = tslp_tsk(timer); 537 540 if ((error != E_OK) && (error != E_TMOUT)) { 538 syslog(LOG_NOTICE, "[NTP CLI,%d] tslp_tsk error: %s %d",541 ntstdio_printf(&ntstdio, "[NTP CLI,%d] tslp_tsk error: %s %d", 539 542 nc->cepid, itron_strerror(error), timer); 540 543 break; … … 543 546 ret = get_tim(&time); 544 547 if (ret != E_OK) { 545 syslog(LOG_NOTICE, "[NTP CLI,%d] get_tim error: %s",548 ntstdio_printf(&ntstdio, "[NTP CLI,%d] get_tim error: %s", 546 549 nc->cepid, itron_strerror(ret)); 547 550 break;
Note:
See TracChangeset
for help on using the changeset viewer.