diff options
author | Artem Bityutskiy <Artem.Bityutskiy@nokia.com> | 2011-04-20 16:32:16 +0300 |
---|---|---|
committer | Artem Bityutskiy <Artem.Bityutskiy@nokia.com> | 2011-04-22 14:29:53 +0300 |
commit | 5fcab90f2d89d472bf0aa70682329e923689c449 (patch) | |
tree | 3e5e511e5ed8ee7478321c59b2f41fb4d5d245c4 /tests/fs-tests/stress/atoms/stress_2.c | |
parent | 9211a3ba80f0300b5476a9c015e4aa80c18e4fbf (diff) |
fs-tests: integck: simplify dirent manipulation
Teach 'add_dir_entry()' to allocate the file/dir/symlink object for
the client. This simplifies client's code. The only place where we
do not want to do this is when we are creating a hardling pointing
to an existing file.
Teach 'remove_dir_entry()' to free the file/dir/symlink object for
the client. Similarly, this simplifies client's code. The only place
where we do not want to do this is the rename function - when we
rename an object we want to only change its direntry, but not the
object itself.
But the main motivation for this change is not just to clean-up, but
to fix another memory leak. In the re-name function we free the
'rename_entry', but we did not free the corresponding object. This
patch fixes the situation.
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Diffstat (limited to 'tests/fs-tests/stress/atoms/stress_2.c')
0 files changed, 0 insertions, 0 deletions