mirror of
https://github.com/ilyakooo0/urbit.git
synced 2024-12-02 07:06:41 +03:00
Merge pull request #894 from belisarius222/flag-non-localhost
Flag non localhost
This commit is contained in:
commit
9a6c3b2832
@ -547,8 +547,8 @@
|
||||
c3_o fog; // -X, skip last event
|
||||
c3_o gab; // -g, run with garbage collector
|
||||
c3_o git; // -s, pill url from arvo git hash
|
||||
c3_o loh; // -L, local-only networking
|
||||
c3_o mem; // -M, memory madness
|
||||
c3_o net; // -N, remote networking in -F mode
|
||||
c3_o nuu; // -c, new pier
|
||||
c3_o pro; // -P, profile
|
||||
c3_o qui; // -q, quiet
|
||||
|
@ -50,8 +50,9 @@ _ames_czar(c3_y imp_y, c3_s* por_s)
|
||||
{
|
||||
u3_ames* sam_u = &u3_Host.sam_u;
|
||||
|
||||
if ( c3y == u3_Host.ops_u.loh ) {
|
||||
if ( c3n == u3_Host.ops_u.net ) {
|
||||
*por_s = 31337 + imp_y;
|
||||
uL(fprintf(uH, "ames: czar: localhost-only mode\n"));
|
||||
return 0x7f000001;
|
||||
}
|
||||
else {
|
||||
|
23
vere/main.c
23
vere/main.c
@ -73,7 +73,7 @@ _main_getopt(c3_i argc, c3_c** argv)
|
||||
u3_Host.ops_u.fog = c3n;
|
||||
u3_Host.ops_u.gab = c3n;
|
||||
u3_Host.ops_u.git = c3n;
|
||||
u3_Host.ops_u.loh = c3n;
|
||||
u3_Host.ops_u.net = c3n;
|
||||
u3_Host.ops_u.mem = c3n;
|
||||
u3_Host.ops_u.nuu = c3n;
|
||||
u3_Host.ops_u.pro = c3n;
|
||||
@ -83,7 +83,7 @@ _main_getopt(c3_i argc, c3_c** argv)
|
||||
u3_Host.ops_u.veb = c3n;
|
||||
u3_Host.ops_u.kno_w = DefaultKernel;
|
||||
|
||||
while ( (ch_i=getopt(argc, argv,"G:B:A:I:w:u:t:f:k:l:n:p:r:LabcdgqsvxFMPDXR")) != -1 ) {
|
||||
while ( (ch_i=getopt(argc, argv,"G:B:A:I:w:u:t:f:k:l:n:p:r:NabcdgqsvxFMPDXR")) != -1 ) {
|
||||
switch ( ch_i ) {
|
||||
case 'M': {
|
||||
u3_Host.ops_u.mem = c3y;
|
||||
@ -162,12 +162,8 @@ _main_getopt(c3_i argc, c3_c** argv)
|
||||
u3_Host.ops_u.rep = c3y;
|
||||
return c3y;
|
||||
}
|
||||
case 'L': { u3_Host.ops_u.loh = c3y; break; }
|
||||
case 'F': {
|
||||
u3_Host.ops_u.loh = c3y;
|
||||
u3_Host.ops_u.fak = c3y;
|
||||
break;
|
||||
}
|
||||
case 'N': { u3_Host.ops_u.net = c3y; break; }
|
||||
case 'F': { u3_Host.ops_u.fak = c3y; break; }
|
||||
case 'a': { u3_Host.ops_u.abo = c3y; break; }
|
||||
case 'b': { u3_Host.ops_u.bat = c3y; break; }
|
||||
case 'c': { u3_Host.ops_u.nuu = c3y; break; }
|
||||
@ -184,6 +180,13 @@ _main_getopt(c3_i argc, c3_c** argv)
|
||||
}
|
||||
}
|
||||
|
||||
if ( u3_Host.ops_u.fak == c3n && u3_Host.ops_u.net == c3y ) {
|
||||
fprintf(stderr, "-N only makes sense with -F\n");
|
||||
return c3n;
|
||||
} else if ( u3_Host.ops_u.fak == c3n && u3_Host.ops_u.net == c3n ) {
|
||||
u3_Host.ops_u.net = c3y; /* remote networking is always on in real mode. */
|
||||
}
|
||||
|
||||
if ( u3_Host.ops_u.arv_c != 0 && ( u3_Host.ops_u.imp_c == 0 ||
|
||||
u3_Host.ops_u.nuu == c3n ) ) {
|
||||
fprintf(stderr, "-A only makes sense when creating a new galaxy\n");
|
||||
@ -197,13 +200,13 @@ _main_getopt(c3_i argc, c3_c** argv)
|
||||
"the initial sync path with -A\n");
|
||||
return c3n;
|
||||
}
|
||||
|
||||
|
||||
if ( u3_Host.ops_u.gen_c != 0 && ( u3_Host.ops_u.imp_c == 0 ||
|
||||
u3_Host.ops_u.nuu == c3n ) ) {
|
||||
fprintf(stderr, "-G only makes sense when creating a new galaxy\n");
|
||||
return c3n;
|
||||
}
|
||||
|
||||
|
||||
if ( u3_Host.ops_u.tic_c != 0 && ( u3_Host.ops_u.imp_c != 0 ||
|
||||
u3_Host.ops_u.nuu == c3n ) ) {
|
||||
fprintf(stderr, "-t only makes sense when creating a new non-galaxy\n");
|
||||
|
Loading…
Reference in New Issue
Block a user