You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by st...@apache.org on 2017/01/24 03:03:04 UTC
[18/50] incubator-mynewt-core git commit: Update for compatibility
with multiple FS
Update for compatibility with multiple FS
Project: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/commit/4326070f
Tree: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/tree/4326070f
Diff: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/diff/4326070f
Branch: refs/heads/sensors_branch
Commit: 4326070fe4b5f9f92c6dca263b9cfb53236537c8
Parents: fb01e49
Author: Fabio Utzig <ut...@utzig.org>
Authored: Thu Jan 19 07:23:19 2017 -0200
Committer: Fabio Utzig <ut...@utzig.org>
Committed: Thu Jan 19 07:23:19 2017 -0200
----------------------------------------------------------------------
fs/fs/src/fs_mkdir.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/4326070f/fs/fs/src/fs_mkdir.c
----------------------------------------------------------------------
diff --git a/fs/fs/src/fs_mkdir.c b/fs/fs/src/fs_mkdir.c
index 546736f..aca27f5 100644
--- a/fs/fs/src/fs_mkdir.c
+++ b/fs/fs/src/fs_mkdir.c
@@ -21,16 +21,18 @@
#include "fs_priv.h"
+struct fs_ops *fops_from_filename(const char *);
+
int
fs_rename(const char *from, const char *to)
{
- struct fs_ops *fops = safe_fs_ops_for("fatfs");
+ struct fs_ops *fops = fops_from_filename(from);
return fops->f_rename(from, to);
}
int
fs_mkdir(const char *path)
{
- struct fs_ops *fops = safe_fs_ops_for("fatfs");
+ struct fs_ops *fops = fops_from_filename(path);
return fops->f_mkdir(path);
}