summaryrefslogtreecommitdiff
path: root/src/fs/virtfsdir.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2017-02-25 19:10:51 +0300
committerAndrei Karas <akaras@inbox.ru>2017-02-25 19:11:57 +0300
commite6198149823ee18e4167b0e6dd34cfb7f2e2f496 (patch)
tree013181d9d8e4f06433838cffaabf6159aa2f775b /src/fs/virtfsdir.cpp
parent0bb68a88e6dc6a04685825e80b4e3dca1dc097d2 (diff)
downloadplus-e6198149823ee18e4167b0e6dd34cfb7f2e2f496.tar.gz
plus-e6198149823ee18e4167b0e6dd34cfb7f2e2f496.tar.bz2
plus-e6198149823ee18e4167b0e6dd34cfb7f2e2f496.tar.xz
plus-e6198149823ee18e4167b0e6dd34cfb7f2e2f496.zip
Implement basic VirtFsZip for virtual fs based on zip archives.
Api similar to VirtFs. For now unused.
Diffstat (limited to 'src/fs/virtfsdir.cpp')
-rw-r--r--src/fs/virtfsdir.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/fs/virtfsdir.cpp b/src/fs/virtfsdir.cpp
index c3471b2d7..249317773 100644
--- a/src/fs/virtfsdir.cpp
+++ b/src/fs/virtfsdir.cpp
@@ -30,6 +30,7 @@
#include "fs/virtlist.h"
#include "utils/checkutils.h"
+#include "utils/dtor.h"
#include "utils/stringutils.h"
#include <dirent.h>
@@ -40,10 +41,6 @@
#include <sys/types.h>
#include <sys/stat.h>
-#ifdef ANDROID
-#include "fs/paths.h"
-#endif // ANDROID
-
#include "debug.h"
extern const char *dirSeparator;
@@ -249,6 +246,7 @@ namespace VirtFsDir
void deinit()
{
+ delete_all(mEntries);
mEntries.clear();
}
@@ -525,7 +523,7 @@ namespace VirtFsDir
const uint64_t pos)
{
if (file == nullptr)
- return -1;
+ return 0;
const int fd = file->mPrivate->mFd;
if (fd == -1)