B
B
BelBES2014-03-22 17:39:42
Android
BelBES, 2014-03-22 17:39:42

Why in Android NativeActivity AAsset_close calls segfault?

The problem is the following. I create a wrapper class over AAssetManager in the native part. The class has an AAsset* asset field. In the class destructor I write something like this:
if(asset) {
AAsset_close(asset);
}
And these lines cause a segfault. If you call AAsset_close outside the destructor, then everything works correctly. Nobody faced this? Thanks in advance!

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question