summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKarel Zak2019-05-16 13:31:30 +0200
committerKarel Zak2019-05-16 13:31:30 +0200
commit4ac2ab97d18fc53b169d492168cc455d55887038 (patch)
tree1507a1fc8bb631986cae48eb423dd10fba0179c2
parentlibsmartcols: (groups) improve scols_table_group_lines() args check [coverity... (diff)
parentlscpu: move trailing null after removing characters from a string (diff)
downloadkernel-qcow2-util-linux-4ac2ab97d18fc53b169d492168cc455d55887038.tar.gz
kernel-qcow2-util-linux-4ac2ab97d18fc53b169d492168cc455d55887038.tar.xz
kernel-qcow2-util-linux-4ac2ab97d18fc53b169d492168cc455d55887038.zip
Merge branch 'lscpu-output-fix' of https://github.com/kerolasa/util-linux
* 'lscpu-output-fix' of https://github.com/kerolasa/util-linux: lscpu: move trailing null after removing characters from a string
-rw-r--r--include/strutils.h1
-rw-r--r--tests/expected/lscpu/lscpu-x86_64-epyc_74512
2 files changed, 2 insertions, 1 deletions
diff --git a/include/strutils.h b/include/strutils.h
index 5584ac5ec..50733c5f5 100644
--- a/include/strutils.h
+++ b/include/strutils.h
@@ -262,6 +262,7 @@ static inline void strrem(char *s, int rem)
if (*s != rem)
*p++ = *s;
}
+ *p = '\0';
}
extern char *strnappend(const char *s, const char *suffix, size_t b);
diff --git a/tests/expected/lscpu/lscpu-x86_64-epyc_7451 b/tests/expected/lscpu/lscpu-x86_64-epyc_7451
index b5abc837c..e93eaf3e6 100644
--- a/tests/expected/lscpu/lscpu-x86_64-epyc_7451
+++ b/tests/expected/lscpu/lscpu-x86_64-epyc_7451
@@ -33,7 +33,7 @@ Vulnerability L1tf: Not affected
Vulnerability Meltdown: Not affected
Vulnerability Spec store bypass: Mitigation; Speculative Store Bypass disabled via prctl and seccomp
Vulnerability Spectre v1: Mitigation; __user pointer sanitization
-Vulnerability Spectre v2: Mitigation; Full AMD retpoline, IBPB conditional, STIBP disabled, RSB fillingng
+Vulnerability Spectre v2: Mitigation; Full AMD retpoline, IBPB conditional, STIBP disabled, RSB filling
Flags: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm constant_tsc rep_good nopl nonstop_tsc cpuid extd_apicid amd_dcm aperfmperf pni pclmulqdq monitor ssse3 fma cx16 sse4_1 sse4_2 movbe popcnt aes xsave avx f16c rdrand lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw skinit wdt tce topoext perfctr_core perfctr_nb bpext perfctr_llc mwaitx cpb hw_pstate ssbd ibpb vmmcall fsgsbase bmi1 avx2 smep bmi2 rdseed adx smap clflushopt sha_ni xsaveopt xsavec xgetbv1 xsaves clzero irperf xsaveerptr arat npt lbrv svm_lock nrip_save tsc_scale vmcb_clean flushbyasid decodeassists pausefilter pfthreshold avic v_vmsave_vmload vgif overflow_recov succor smca
# The following is the parsable format, which can be fed to other