mirror of
https://gitee.com/openharmony/third_party_f2fs-tools
synced 2024-11-27 04:00:57 +00:00
f2fs-tools: correct get kernel version logic
commit 3218ff95d9
category: bugfix
issue: #I6VAS0
CVE: NA
Signed-off-by: DongSenhao <dongsenhao2@huawei.com>
---------------------------------------
Current implementation, If define WITH_KERNEL_VERSION
get_kernel_uname_version just return release info, not define
WITH_KERNEL_VERSION, return release and version info.
So remove "!" in get_kernel_uname_version, make logic more clear.
Signed-off-by: lijiazi <lijiazi@xiaomi.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Signed-off-by: dongsenhao <dongsenhao2@huawei.com>
This commit is contained in:
parent
31d2f7c45a
commit
0c15655e55
@ -837,7 +837,7 @@ void get_kernel_uname_version(__u8 *version)
|
||||
if (uname(&buf))
|
||||
return;
|
||||
|
||||
#if !defined(WITH_KERNEL_VERSION)
|
||||
#if defined(WITH_KERNEL_VERSION)
|
||||
snprintf((char *)version,
|
||||
VERSION_LEN, "%s %s", buf.release, buf.version);
|
||||
#else
|
||||
|
Loading…
Reference in New Issue
Block a user