Diff

Differences From Artifact [972cb23bc8]:

To Artifact [ca96d213e2]:


218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235


























































236
237
238
239
240
241
242
	    }
	    command[cmdlen++] = d;
	} while (c != EOF);
	cfg.remote_cmd_ptr = command;
	cfg.remote_cmd_ptr2 = NULL;
	cfg.nopty = TRUE;      /* command => no terminal */
    }
    if (!strcmp(p, "-P")) {
	RETURN(2);
	SAVEABLE(2);		       /* lower priority than -ssh,-telnet */
	cfg.port = atoi(value);
    }
    if (!strcmp(p, "-pw")) {
	RETURN(2);
	cmdline_password = value;
	ssh_get_line = cmdline_get_line;
	ssh_getline_pw_only = TRUE;
    }


























































    return ret;			       /* unrecognised */
}

void cmdline_run_saved(void)
{
    int pri, i;
    for (pri = 0; pri < NPRIORITIES; pri++)







|










>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
	    }
	    command[cmdlen++] = d;
	} while (c != EOF);
	cfg.remote_cmd_ptr = command;
	cfg.remote_cmd_ptr2 = NULL;
	cfg.nopty = TRUE;      /* command => no terminal */
    }
    if (!strcmp(p, "-P") || !strcmp(p, "-p")) {
	RETURN(2);
	SAVEABLE(2);		       /* lower priority than -ssh,-telnet */
	cfg.port = atoi(value);
    }
    if (!strcmp(p, "-pw")) {
	RETURN(2);
	cmdline_password = value;
	ssh_get_line = cmdline_get_line;
	ssh_getline_pw_only = TRUE;
    }

    if (!strcmp(p, "-A")) {
	RETURN(1);
	SAVEABLE(1);
	cfg.agentfwd = 1;
    }
    if (!strcmp(p, "-a")) {
	RETURN(1);
	SAVEABLE(1);
	cfg.agentfwd = 0;
    }

    if (!strcmp(p, "-X")) {
	RETURN(1);
	SAVEABLE(1);
	cfg.x11_forward = 1;
    }
    if (!strcmp(p, "-x")) {
	RETURN(1);
	SAVEABLE(1);
	cfg.x11_forward = 0;
    }

    if (!strcmp(p, "-t")) {
	RETURN(1);
	SAVEABLE(1);
	cfg.nopty = 0;
    }
    if (!strcmp(p, "-T")) {
	RETURN(1);
	SAVEABLE(1);
	cfg.nopty = 1;
    }

    if (!strcmp(p, "-C")) {
	RETURN(1);
	SAVEABLE(1);
	cfg.compression = 1;
    }

    if (!strcmp(p, "-1")) {
	RETURN(1);
	SAVEABLE(1);
	cfg.sshprot = 0;	       /* ssh protocol 1 only */
    }
    if (!strcmp(p, "-2")) {
	RETURN(1);
	SAVEABLE(1);
	cfg.sshprot = 3;	       /* ssh protocol 2 only */
    }

    if (!strcmp(p, "-i")) {
	RETURN(2);
	SAVEABLE(1);
	strncpy(cfg.keyfile, value, sizeof(cfg.keyfile));
	cfg.keyfile[sizeof(cfg.keyfile)-1] = '\0';
    }

    return ret;			       /* unrecognised */
}

void cmdline_run_saved(void)
{
    int pri, i;
    for (pri = 0; pri < NPRIORITIES; pri++)