Commit | Line | Data |
---|---|---|
99c3da2c FF |
1 | Handle EROFS. This is since path_remove_tree() will be called with |
2 | '/data.dpkg-tmp' | |
3 | '/data/data.dpkg-tmp' | |
4 | '/data/data/com.termux.dpkg-tmp' | |
5 | '/data/data/com.termux/files.dpkg-tmp' | |
6 | '/data/data/com.termux/files/usr.dpkg-tmp' | |
7 | and the first call will get a EROFS, read-only file system error. | |
8 | ||
9 | diff -u -r ../dpkg-1.18.2/lib/dpkg/path-remove.c ./lib/dpkg/path-remove.c | |
10 | --- ../dpkg-1.18.2/lib/dpkg/path-remove.c 2015-07-30 00:39:24.000000000 -0400 | |
11 | +++ ./lib/dpkg/path-remove.c 2015-08-25 18:04:31.391421421 -0400 | |
12 | @@ -126,7 +126,7 @@ | |
13 | debug(dbg_eachfile, "%s '%s'", __func__, pathname); | |
14 | if (!rmdir(pathname)) | |
15 | return; /* Deleted it OK, it was a directory. */ | |
16 | - if (errno == ENOENT || errno == ELOOP) | |
17 | + if (errno == ENOENT || errno == ELOOP || errno == EROFS) | |
18 | return; | |
19 | if (errno == ENOTDIR) { | |
20 | /* Either it's a file, or one of the path components is. If |