Revert "archive: Use memfd instead"
* It sucks, seems simplify the conditions, but more syscalls are
made(read/seek/write), more context switch, futhermore AImageDecoder itself does support
read raw buffer, and we are not intend to support multi-process decoding
This reverts commit f4826ea727.
This commit is contained in:
1 parent
f4826ea727
commit
a0fe6f0d7d
6 files changed
+63
-25
No files matched your search
@@ -21,6 +21,10 @@ package com.hippo;
|
||||
import android.content.Context;
|
||||
import android.net.Uri;
|
||||
import android.os.ParcelFileDescriptor;
|
||||
import android.system.Os;
|
||||
import android.system.OsConstants;
|
||||
|
||||
import java.io.FileDescriptor;
|
||||
|
||||
public class UriArchiveAccessor {
|
||||
ParcelFileDescriptor pfd;
|
||||
@@ -39,7 +43,7 @@ public class UriArchiveAccessor {
|
||||
|
||||
private native int openArchive(int fd, long size);
|
||||
|
||||
public native int extractToMemfd(int index);
|
||||
public native long extracttoOutputStream(int index);
|
||||
|
||||
public native boolean needPassword();
|
||||
|
||||
|
||||
Reference in new issue
Block a user