mirror of
https://github.com/ibm-s390-linux/s390-tools.git
synced 2026-08-05 02:14:52 +00:00
zdev: use libutil provided path functions
Closes: #20 Signed-off-by: Rafael Fonseca <r4f4rfs@gmail.com> Acked-by: Peter Oberparleiter <oberpar@linux.vnet.ibm.com> Signed-off-by: Michael Holzheu <holzheu@linux.vnet.ibm.com>
This commit is contained in:
committed by
Michael Holzheu
parent
df133846b5
commit
d542138868
+4
-1
@@ -11,6 +11,8 @@
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
#include "lib/util_path.h"
|
||||
|
||||
#include "attrib.h"
|
||||
#include "device.h"
|
||||
#include "devtype.h"
|
||||
@@ -480,7 +482,8 @@ void device_read_active_settings(struct device *dev, read_scope_t scope)
|
||||
a = attrib_find(st->dev_attribs, name);
|
||||
s = setting_list_apply_actual(dev->active.settings, a, name,
|
||||
value);
|
||||
if (link || (scope == scope_all && !file_writable(path)))
|
||||
if (link || (scope == scope_all &&
|
||||
!util_path_is_writable(path)))
|
||||
s->readonly = 1;
|
||||
if (link)
|
||||
free(link);
|
||||
|
||||
Reference in New Issue
Block a user