mirror of
https://gitlab.com/chrony/chrony.git
synced 2025-12-03 19:55:07 -05:00
main: don't require root privileges with -Q option
If the -Q option is specified, disable by default pidfile, ntpport, cmdport, Unix domain command socket, and clock control, in order to allow starting chronyd without root privileges and/or when another chronyd instance is already running.
This commit is contained in:
@@ -33,7 +33,7 @@ test_unit(void)
|
||||
"cmdratelimit interval 3 burst 4 leak 3",
|
||||
};
|
||||
|
||||
CNF_Initialise(0);
|
||||
CNF_Initialise(0, 0);
|
||||
for (i = 0; i < sizeof conf / sizeof conf[0]; i++)
|
||||
CNF_ParseLine(NULL, i + 1, conf[i]);
|
||||
|
||||
|
||||
@@ -90,7 +90,7 @@ test_unit(void)
|
||||
"keyfile "KEYFILE
|
||||
};
|
||||
|
||||
CNF_Initialise(0);
|
||||
CNF_Initialise(0, 0);
|
||||
for (i = 0; i < sizeof conf / sizeof conf[0]; i++)
|
||||
CNF_ParseLine(NULL, i + 1, conf[i]);
|
||||
|
||||
|
||||
@@ -218,7 +218,7 @@ test_unit(void)
|
||||
CPS_NTP_Source source;
|
||||
NTP_Remote_Address remote_addr;
|
||||
|
||||
CNF_Initialise(0);
|
||||
CNF_Initialise(0, 0);
|
||||
for (i = 0; i < sizeof conf / sizeof conf[0]; i++)
|
||||
CNF_ParseLine(NULL, i + 1, conf[i]);
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@ test_unit(void)
|
||||
|
||||
memset(¶ms, 0, sizeof (params));
|
||||
|
||||
CNF_Initialise(0);
|
||||
CNF_Initialise(0, 0);
|
||||
CNF_ParseLine(NULL, 1, conf);
|
||||
|
||||
LCL_Initialise();
|
||||
|
||||
@@ -29,7 +29,7 @@ test_unit(void)
|
||||
double offset, freq, wander;
|
||||
char conf[] = "smoothtime 300 0.01";
|
||||
|
||||
CNF_Initialise(0);
|
||||
CNF_Initialise(0, 0);
|
||||
CNF_ParseLine(NULL, 1, conf);
|
||||
|
||||
LCL_Initialise();
|
||||
|
||||
@@ -31,7 +31,7 @@ test_unit(void)
|
||||
double offset, delay, disp;
|
||||
struct timespec ts;
|
||||
|
||||
CNF_Initialise(0);
|
||||
CNF_Initialise(0, 0);
|
||||
LCL_Initialise();
|
||||
TST_RegisterDummyDrivers();
|
||||
SCH_Initialise();
|
||||
|
||||
Reference in New Issue
Block a user