Re: [PATCH 2/4] ubifs: Fix unlink code wrt. double hash lookups

2017-07-16 Thread Richard Weinberger
Am 16.07.2017 um 14:17 schrieb Richard Weinberger: > Geert, > > Am 16.07.2017 um 14:12 schrieb Geert Uytterhoeven: >> Hi Richard, >> >> On Sun, Mar 19, 2017 at 9:46 PM, Richard Weinberger wrote: >>> Am 09.03.2017 um 08:04 schrieb Hyunchul Lee: > -int n, err, type = key_type(c, key); >>>

Re: [PATCH 2/4] ubifs: Fix unlink code wrt. double hash lookups

2017-07-16 Thread Richard Weinberger
Geert, Am 16.07.2017 um 14:12 schrieb Geert Uytterhoeven: > Hi Richard, > > On Sun, Mar 19, 2017 at 9:46 PM, Richard Weinberger wrote: >> Am 09.03.2017 um 08:04 schrieb Hyunchul Lee: -int n, err, type = key_type(c, key); -struct ubifs_znode *znode; +int err; > > f

Re: [PATCH 2/4] ubifs: Fix unlink code wrt. double hash lookups

2017-07-16 Thread Geert Uytterhoeven
Hi Richard, On Sun, Mar 19, 2017 at 9:46 PM, Richard Weinberger wrote: > Am 09.03.2017 um 08:04 schrieb Hyunchul Lee: >>> -int n, err, type = key_type(c, key); >>> -struct ubifs_znode *znode; >>> +int err; fs/ubifs/tnc.c: In function ‘search_dh_cookie’: fs/ubifs/tnc.c:1893: w

Re: [PATCH 2/4] ubifs: Fix unlink code wrt. double hash lookups

2017-03-19 Thread Richard Weinberger
Hyunchul, Am 09.03.2017 um 08:04 schrieb Hyunchul Lee: >> -int n, err, type = key_type(c, key); >> -struct ubifs_znode *znode; >> +int err; > > i guess that err should be initialized with -ENOENT to avoid the first call > of > tnc_next(c, &znode, n). Yes. err is used unitialized.

Re: [PATCH 2/4] ubifs: Fix unlink code wrt. double hash lookups

2017-03-08 Thread Hyunchul Lee
Richard, this patch works well. but i found some trivial mistakes. On Thu, Feb 09, 2017 at 10:28:35PM +0100, Richard Weinberger wrote: > When removing an encrypted file with a long anem and without having > the key we have to be able to locate and remove the directory entry > via a double hash. T

[PATCH 2/4] ubifs: Fix unlink code wrt. double hash lookups

2017-02-09 Thread Richard Weinberger
When removing an encrypted file with a long anem and without having the key we have to be able to locate and remove the directory entry via a double hash. This corner case was simply forgotten. Reported-by: David Oberhollenzer Signed-off-by: Richard Weinberger --- fs/ubifs/journal.c | 10 -