diff options
author | Daniel Walter <dwalter@sigma-star.at> | 2016-08-31 10:05:36 +0200 |
---|---|---|
committer | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2016-11-17 11:36:56 +0100 |
commit | e7974ec2eae0f0142112028d8b7bd0af0c0c5ebb (patch) | |
tree | be7dbf58e3ca03c68de2570695114a93e2c080b2 /ubi-utils/libubi.c | |
parent | 4adc61baeba93bc08749c7586d0a36bee01ece8d (diff) |
Add support for sysfs mocking
In order to use test files, allow sysfs root
to be set during compile time
Signed-off-by: Daniel Walter <dwalter@sigma-star.at>
Diffstat (limited to 'ubi-utils/libubi.c')
-rw-r--r-- | ubi-utils/libubi.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ubi-utils/libubi.c b/ubi-utils/libubi.c index 97c0434..758d351 100644 --- a/ubi-utils/libubi.c +++ b/ubi-utils/libubi.c @@ -524,7 +524,7 @@ libubi_t libubi_open(void) if (!lib) return NULL; - lib->sysfs_ctrl = mkpath("/sys", SYSFS_CTRL); + lib->sysfs_ctrl = mkpath(SYSFS_ROOT, SYSFS_CTRL); if (!lib->sysfs_ctrl) goto out_error; @@ -532,7 +532,7 @@ libubi_t libubi_open(void) if (!lib->ctrl_dev) goto out_error; - lib->sysfs_ubi = mkpath("/sys", SYSFS_UBI); + lib->sysfs_ubi = mkpath(SYSFS_ROOT, SYSFS_UBI); if (!lib->sysfs_ubi) goto out_error; |