summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2019-11-21 08:37:12 +0100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2019-11-21 09:06:56 +0100
commit11455b2e6d7799297332a31a09496177ab792b27 (patch)
treee03f78a38c4f4df61a22af1deaa646c2853361b7
parentf3779985681baaa4ac4e33dddfabab241008376c (diff)
downloadrtems-11455b2e6d7799297332a31a09496177ab792b27.tar.bz2
imfs: Fix IMFS_make_linearfile()
Fix prototype. Fix node size. Linfiles are dynamically turned into memfiles. Update #3823.
-rw-r--r--cpukit/include/rtems/imfs.h2
-rw-r--r--cpukit/libfs/src/imfs/imfs_make_linfile.c4
2 files changed, 3 insertions, 3 deletions
diff --git a/cpukit/include/rtems/imfs.h b/cpukit/include/rtems/imfs.h
index 27105fc257..5327d632f9 100644
--- a/cpukit/include/rtems/imfs.h
+++ b/cpukit/include/rtems/imfs.h
@@ -619,7 +619,7 @@ extern int IMFS_make_node(
extern int IMFS_make_linearfile(
const char *path,
mode_t mode,
- const char *data,
+ const void *data,
size_t size
);
diff --git a/cpukit/libfs/src/imfs/imfs_make_linfile.c b/cpukit/libfs/src/imfs/imfs_make_linfile.c
index d5f1d0e21f..2eef953da5 100644
--- a/cpukit/libfs/src/imfs/imfs_make_linfile.c
+++ b/cpukit/libfs/src/imfs/imfs_make_linfile.c
@@ -34,7 +34,7 @@
int IMFS_make_linearfile(
const char *path,
mode_t mode,
- const char *data,
+ const void *data,
size_t size
)
{
@@ -47,7 +47,7 @@ int IMFS_make_linearfile(
path,
( mode & ~S_IFMT ) | S_IFREG,
&IMFS_node_control_linfile,
- sizeof( IMFS_linearfile_t ),
+ sizeof( IMFS_file_t ),
&ctx
);
}