| 552 | } |
| 553 | |
| 554 | int Arguments::parseTimeout(const char* str) { |
| 555 | const char* p = strchr(str, ':'); |
| 556 | if (p == NULL) { |
| 557 | return parseUnits(str, SECONDS); |
| 558 | } |
| 559 | |
| 560 | int hh = str[0] >= '0' && str[0] <= '2' ? atoi(str) : 0xff; |
| 561 | int mm = p[1] >= '0' && p[1] <= '5' ? atoi(p + 1) : 0xff; |
| 562 | int ss = (p = strchr(p + 1, ':')) != NULL && p[1] >= '0' && p[1] <= '5' ? atoi(p + 1) : 0xff; |
| 563 | return 0xff000000 | hh << 16 | mm << 8 | ss; |
| 564 | } |
| 565 | |
| 566 | Arguments::~Arguments() { |
| 567 | if (!_shared) free(_buf); |
nothing calls this directly
no outgoing calls
no test coverage detected