Skip to content
Snippets Groups Projects
Commit 9d2f6a9a authored by Gary Bisson's avatar Gary Bisson Committed by Tom Rini
Browse files

fs: ext4: fix symlink read function


Since last API changes for files >2GB, the read of symlink is broken as
ext4fs_read_file now returns 0 instead of the length of the actual read.

Signed-off-by: default avatarGary Bisson <gary.bisson@boundarydevices.com>
parent 40372244
Branches
Tags
No related merge requests found
...@@ -2046,7 +2046,7 @@ static char *ext4fs_read_symlink(struct ext2fs_node *node) ...@@ -2046,7 +2046,7 @@ static char *ext4fs_read_symlink(struct ext2fs_node *node)
status = ext4fs_read_file(diro, 0, status = ext4fs_read_file(diro, 0,
__le32_to_cpu(diro->inode.size), __le32_to_cpu(diro->inode.size),
symlink, &actread); symlink, &actread);
if (status == 0) { if ((status < 0) || (actread == 0)) {
free(symlink); free(symlink);
return 0; return 0;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment