mirror of
https://github.com/systemd/systemd
synced 2025-09-30 17:24:46 +02:00
Compare commits
4 Commits
228f5ed3a4
...
8dfc2beb57
Author | SHA1 | Date | |
---|---|---|---|
![]() |
8dfc2beb57 | ||
![]() |
505061bb4f | ||
![]() |
8aa35d09d3 | ||
![]() |
77552b9520 |
12
.github/ISSUE_TEMPLATE/Bug_report.md
vendored
12
.github/ISSUE_TEMPLATE/Bug_report.md
vendored
@ -31,3 +31,15 @@ about: A report of an error in a recent systemd version
|
|||||||
|
|
||||||
**Steps to reproduce the problem**
|
**Steps to reproduce the problem**
|
||||||
> …
|
> …
|
||||||
|
|
||||||
|
**Additional program output to the terminal or log subsystem illustrating the issue**
|
||||||
|
|
||||||
|
<!-- Please paste relevant program terminal or journal output here, ideally
|
||||||
|
when generated in debug mode (try setting the SYSTEMD_LOG_LEVEL=debug
|
||||||
|
environment variable). For very long copy/pasted data consider using a
|
||||||
|
service like https://gist.github.com/. Where copy/paste is not possible
|
||||||
|
(for example early boot or late shutdown), a photo of the screen might do
|
||||||
|
too, but text is always much preferred. -->
|
||||||
|
```text
|
||||||
|
…
|
||||||
|
```
|
||||||
|
@ -1545,7 +1545,7 @@ static int assess(const struct security_info *info, Table *overview_table, Analy
|
|||||||
|
|
||||||
if (a->default_dependencies_only && !info->default_dependencies) {
|
if (a->default_dependencies_only && !info->default_dependencies) {
|
||||||
badness = UINT64_MAX;
|
badness = UINT64_MAX;
|
||||||
d = strdup("Service runs in special boot phase, option does not apply");
|
d = strdup("Service runs in special boot phase, option is not appropriate");
|
||||||
if (!d)
|
if (!d)
|
||||||
return log_oom();
|
return log_oom();
|
||||||
} else {
|
} else {
|
||||||
|
@ -96,8 +96,7 @@ int clock_is_localtime(const char* adjtime_path) {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
int clock_set_timezone(int *min) {
|
int clock_set_timezone(int *ret_minutesdelta) {
|
||||||
const struct timeval *tv_null = NULL;
|
|
||||||
struct timespec ts;
|
struct timespec ts;
|
||||||
struct tm tm;
|
struct tm tm;
|
||||||
int minutesdelta;
|
int minutesdelta;
|
||||||
@ -107,36 +106,32 @@ int clock_set_timezone(int *min) {
|
|||||||
assert_se(localtime_r(&ts.tv_sec, &tm));
|
assert_se(localtime_r(&ts.tv_sec, &tm));
|
||||||
minutesdelta = tm.tm_gmtoff / 60;
|
minutesdelta = tm.tm_gmtoff / 60;
|
||||||
|
|
||||||
tz.tz_minuteswest = -minutesdelta;
|
tz = (struct timezone) {
|
||||||
tz.tz_dsttime = 0; /* DST_NONE */
|
.tz_minuteswest = -minutesdelta,
|
||||||
|
.tz_dsttime = 0, /* DST_NONE */
|
||||||
|
};
|
||||||
|
|
||||||
/*
|
/* If the RTC does not run in UTC but in local time, the very first call to settimeofday() will set
|
||||||
* If the RTC does not run in UTC but in local time, the very first
|
* the kernel's timezone and will warp the system clock, so that it runs in UTC instead of the local
|
||||||
* call to settimeofday() will set the kernel's timezone and will warp the
|
* time we have read from the RTC. */
|
||||||
* system clock, so that it runs in UTC instead of the local time we
|
if (settimeofday(NULL, &tz) < 0)
|
||||||
* have read from the RTC.
|
return -errno;
|
||||||
*/
|
|
||||||
if (settimeofday(tv_null, &tz) < 0)
|
if (ret_minutesdelta)
|
||||||
return negative_errno();
|
*ret_minutesdelta = minutesdelta;
|
||||||
|
|
||||||
if (min)
|
|
||||||
*min = minutesdelta;
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
int clock_reset_timewarp(void) {
|
int clock_reset_timewarp(void) {
|
||||||
const struct timeval *tv_null = NULL;
|
static const struct timezone tz = {
|
||||||
struct timezone tz;
|
.tz_minuteswest = 0,
|
||||||
|
.tz_dsttime = 0, /* DST_NONE */
|
||||||
|
};
|
||||||
|
|
||||||
tz.tz_minuteswest = 0;
|
/* The very first call to settimeofday() does time warp magic. Do a dummy call here, so the time
|
||||||
tz.tz_dsttime = 0; /* DST_NONE */
|
* warping is sealed and all later calls behave as expected. */
|
||||||
|
if (settimeofday(NULL, &tz) < 0)
|
||||||
/*
|
|
||||||
* The very first call to settimeofday() does time warp magic. Do a
|
|
||||||
* dummy call here, so the time warping is sealed and all later calls
|
|
||||||
* behave as expected.
|
|
||||||
*/
|
|
||||||
if (settimeofday(tv_null, &tz) < 0)
|
|
||||||
return -errno;
|
return -errno;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
@ -917,7 +917,7 @@ static void test_strverscmp_improved(void) {
|
|||||||
"123-3.1",
|
"123-3.1",
|
||||||
"123^patch1",
|
"123^patch1",
|
||||||
"123^1",
|
"123^1",
|
||||||
"123.a-1"
|
"123.a-1",
|
||||||
"123.1-1",
|
"123.1-1",
|
||||||
"123a-1",
|
"123a-1",
|
||||||
"124",
|
"124",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user