Browse Source

Re-style previous patch b9d624f

tags/v1.00
Quentin Rameau 2 years ago
parent
commit
551de29834
3 changed files with 12 additions and 14 deletions
  1. +8
    -10
      sacc.c
  2. +2
    -2
      ui_ti.c
  3. +2
    -2
      ui_txt.c

+ 8
- 10
sacc.c View File

@@ -619,19 +619,10 @@ dig(Item *entry, Item *item)
case '9':
downloaditem(item);
return 0;
case 'T':
if (asprintf(&plumburi, "tn3270://%s@%s:%s", item->selector,
item->host, item->port) < 0) {
return 0;
}
plumb(plumburi);
free(plumburi);
return 0;
case '8':
if (asprintf(&plumburi, "telnet://%s@%s:%s", item->selector,
item->host, item->port) < 0) {
item->host, item->port) < 0)
return 0;
}
plumb(plumburi);
free(plumburi);
return 0;
@@ -640,6 +631,13 @@ dig(Item *entry, Item *item)
case 'I':
plumbitem(item);
return 0;
case 'T':
if (asprintf(&plumburi, "tn3270://%s@%s:%s", item->selector,
item->host, item->port) < 0)
return 0;
plumb(plumburi);
free(plumburi);
return 0;
default:
uistatus("Type %c (%s) not supported",
item->type, typedisplay(item->type));


+ 2
- 2
ui_ti.c View File

@@ -210,7 +210,7 @@ displayuri(Item *item)
switch (item->type) {
case '8':
n = snprintf(bufout, sizeof(bufout), "telnet://%s@%s:%s",
item->selector, item->host, item->port);
item->selector, item->host, item->port);
break;
case 'h':
n = snprintf(bufout, sizeof(bufout), "%s: %s",
@@ -218,7 +218,7 @@ displayuri(Item *item)
break;
case 'T':
n = snprintf(bufout, sizeof(bufout), "tn3270://%s@%s:%s",
item->selector, item->host, item->port);
item->selector, item->host, item->port);
break;
default:
fmt = strcmp(item->port, "70") ?


+ 2
- 2
ui_txt.c View File

@@ -183,7 +183,7 @@ printuri(Item *item, size_t i)
return;
case '8':
n = snprintf(bufout, sizeof(bufout), "telnet://%s@%s:%s",
item->selector, item->host, item->port);
item->selector, item->host, item->port);
break;
case 'i':
n = snprintf(bufout, sizeof(bufout), "%zu: %s",
@@ -195,7 +195,7 @@ printuri(Item *item, size_t i)
break;
case 'T':
n = snprintf(bufout, sizeof(bufout), "tn3270://%s@%s:%s",
item->selector, item->host, item->port);
item->selector, item->host, item->port);
break;
default:
fmt = strcmp(item->port, "70") ?


Loading…
Cancel
Save