fs/romfs/fs_romfs.c: Fix syslog format errors

This commit is contained in:
YAMAMOTO Takashi
2020-11-20 12:02:05 +09:00
committed by Xiang Xiao
parent bc9e28eb35
commit da1b593485
+4 -4
View File
@@ -254,7 +254,7 @@ static int romfs_open(FAR struct file *filep, FAR const char *relpath,
rf = (FAR struct romfs_file_s *)kmm_zalloc(sizeof(struct romfs_file_s)); rf = (FAR struct romfs_file_s *)kmm_zalloc(sizeof(struct romfs_file_s));
if (!rf) if (!rf)
{ {
ferr("ERROR: Failed to allocate private data\n", ret); ferr("ERROR: Failed to allocate private data\n");
ret = -ENOMEM; ret = -ENOMEM;
goto errout_with_semaphore; goto errout_with_semaphore;
} }
@@ -375,7 +375,7 @@ static ssize_t romfs_read(FAR struct file *filep, FAR char *buffer,
int sectorndx; int sectorndx;
int ret; int ret;
finfo("Read %d bytes from offset %d\n", buflen, filep->f_pos); finfo("Read %zu bytes from offset %d\n", buflen, filep->f_pos);
/* Sanity checks */ /* Sanity checks */
@@ -676,7 +676,7 @@ static int romfs_dup(FAR const struct file *oldp, FAR struct file *newp)
newrf = (FAR struct romfs_file_s *)kmm_malloc(sizeof(struct romfs_file_s)); newrf = (FAR struct romfs_file_s *)kmm_malloc(sizeof(struct romfs_file_s));
if (!newrf) if (!newrf)
{ {
ferr("ERROR: Failed to allocate private data\n", ret); ferr("ERROR: Failed to allocate private data\n");
ret = -ENOMEM; ret = -ENOMEM;
goto errout_with_semaphore; goto errout_with_semaphore;
} }
@@ -824,7 +824,7 @@ static int romfs_opendir(FAR struct inode *mountpt, FAR const char *relpath,
{ {
/* The entry is not a directory */ /* The entry is not a directory */
ferr("ERROR: '%s' is not a directory: %d\n", relpath); ferr("ERROR: '%s' is not a directory\n", relpath);
ret = -ENOTDIR; ret = -ENOTDIR;
goto errout_with_semaphore; goto errout_with_semaphore;
} }