[U-Boot] [PATCH v3 1/2] fs: fat: cannot write to subdirectories
Simon Glass
sjg at chromium.org
Mon Jul 9 02:35:23 UTC 2018
Hi Heinrich,
On 1 July 2018 at 17:41, Heinrich Schuchardt <xypron.glpk at gmx.de> wrote:
> fs_fat_write() is not able to write to subdirectories.
>
> Currently if a filepath with a leading slash is passed, the slash is
> treated as part of the filename to be created in the root directory.
>
> Strip leading (back-)slashes.
>
> Check that the remaining filename does not contain any illegal characters
> (<>:"/\|?*). This way we will throw an error when trying to write to a
> subdirectory.
>
> Signed-off-by: Heinrich Schuchardt <xypron.glpk at gmx.de>
> ---
> fs/fat/fat_write.c | 16 +++++++++++++++-
> 1 file changed, 15 insertions(+), 1 deletion(-)
It would be great if we have filesystem tests. We do have the
fs-test.sh script but it is not using pytest, so best not to build on
it.
Regards,
Simon
More information about the U-Boot
mailing list