mirror of
https://github.com/tio/tio.git
synced 2026-05-01 14:57:59 +02:00
Do not expose timestamp-format 'none' option
Do not expose the 'none' timestamp-format option. It is and internal state used when timestamp is disabled.
This commit is contained in:
parent
d598fa76a7
commit
683aab1dc7
2 changed files with 2 additions and 9 deletions
|
|
@ -53,6 +53,7 @@ char *current_time(void)
|
|||
switch (option.timestamp)
|
||||
{
|
||||
case TIMESTAMP_NONE:
|
||||
return NULL;
|
||||
case TIMESTAMP_24HOUR:
|
||||
// "hh:mm:ss.sss" (24 hour format)
|
||||
tv = tv_now;
|
||||
|
|
|
|||
|
|
@ -105,10 +105,6 @@ const char* timestamp_token(enum timestamp_t timestamp)
|
|||
{
|
||||
switch (timestamp)
|
||||
{
|
||||
case TIMESTAMP_NONE:
|
||||
return "none";
|
||||
break;
|
||||
|
||||
case TIMESTAMP_24HOUR:
|
||||
return "24hour";
|
||||
break;
|
||||
|
|
@ -137,11 +133,7 @@ enum timestamp_t timestamp_option_parse(const char *arg)
|
|||
|
||||
if (arg != NULL)
|
||||
{
|
||||
if (strcmp(arg, "none") == 0)
|
||||
{
|
||||
return TIMESTAMP_NONE;
|
||||
}
|
||||
else if (strcmp(arg, "24hour") == 0)
|
||||
if (strcmp(arg, "24hour") == 0)
|
||||
{
|
||||
return TIMESTAMP_24HOUR;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue