Deleted Added
full compact
20c20
< * $Id: command.c,v 1.51 1997/05/29 02:29:12 brian Exp $
---
> * $Id: command.c,v 1.52 1997/05/31 16:37:19 brian Exp $
374a375,389
> static int ShowInitialMRU()
> {
> printf(" Initial MRU: %ld\n", VarMRU);
> return(1);
> }
>
> static int ShowPreferredMTU()
> {
> if (VarPrefMTU)
> printf(" Preferred MTU: %ld\n", VarPrefMTU);
> else
> printf(" Preferred MTU: unspecified\n");
> return(1);
> }
>
453a469,472
> { "mru", NULL, ShowInitialMRU, LOCAL_AUTH,
> "Show Initial MRU", StrNull},
> { "mtu", NULL, ShowPreferredMTU, LOCAL_AUTH,
> "Show Preferred MTU", StrNull},
837c856
< int mru;
---
> long mru;
840,842c859,861
< mru = atoi(*argv);
< if (mru < 100)
< printf("given value is too small.\n");
---
> mru = atol(*argv);
> if (mru < MIN_MRU)
> printf("Given MRU value (%ld) is too small.\n", mru);
844c863
< printf("given value is too big.\n");
---
> printf("Given MRU value (%ld) is too big.\n", mru);
847c866,868
< }
---
> } else
> printf("Usage: %s %s\n", list->name, list->syntax);
>
851a873,896
> SetPreferredMTU(list, argc, argv)
> struct cmdtab *list;
> int argc;
> char **argv;
> {
> long mtu;
>
> if (argc > 0) {
> mtu = atol(*argv);
> if (mtu == 0)
> VarPrefMTU = 0;
> else if (mtu < MIN_MTU)
> printf("Given MTU value (%ld) is too small.\n", mtu);
> else if (mtu > MAX_MTU)
> printf("Given MTU value (%ld) is too big.\n", mtu);
> else
> VarPrefMTU = mtu;
> } else
> printf("Usage: %s %s\n", list->name, list->syntax);
>
> return(1);
> }
>
> static int
1119a1165,1166
> { "mtu", NULL, SetPreferredMTU, LOCAL_AUTH,
> "Set Preferred MTU value", StrValue },