Webview cache FALLBACK crash?

by Neil » Fri, 25 Feb 2011 12:57:23 GMT


Sponsored Links
 Hiya

I've scoured the net for days, but I can't work this one out.

I had a WebView that uses the HTML5 cache manifest file.  All seems to
work fine, I can view pages offline etc, except when I try and view a
page that isn't in the cache, then my app restarts or quits.

Any ideas?  Perhaps I can check to see if a page is cached before I
let the webview visit it - but how do I do this check?

My test device is a Hero running the standard 2.1 (ie as HTC
intended).  Perhaps this is "just" an issue with 2.1?

I'm assuming the caching is working ok - certainly seems to, though
Astro can't find any files on the device with my app name..

Help!

Thanks :)

Neil

-- 



Other Threads

1. Android-NDK, porting openssl

Hello everyone !

I hope you can help me, because I am losing my mind trying to port
OpenSSL on Android....

I got the last release of the external package for android from this
repository : http://github.com/android/platform_external_openssl and I
tried to generate shared librairies to use them into Eclipse. Here is
what I've done and the structure of what I've made :


I created a new apps called "openssl" and added the last release in
the jni folder of "project" in it.

So here is the structure :

j...@jiss:/android-ndk-r3/apps/openssl$ ls -l

Application.mk   project/

j...@jiss:/android-ndk-r3/apps/openssl$ cd project/
j...@jiss:/android-ndk-r3/apps/openssl/project$ ls

jni/

j...@jiss:/android-ndk-r3/apps/openssl/project$ cd jni/
j...@jiss:/android-ndk-r3/apps/openssl/project/jni$ ls

android-config.mk  crypto/   include/    README.android
Android.mk         e_os2.h  MODULE_LICENSE_BSD_LIKE  ssl/
apps/    e_os.h   NOTICE


So here is the structure of what I've made.


Then I set up the NDK going to the root of the NDK and typing "  ./
build/host-setup.sh   "


Then I type   "make APP=openssl"


And i get an error, here is what I get :



j...@jiss:/android-ndk-r3$ make APP=openssl
Android NDK: Building for application 'openssl'
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/cryptlib.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/mem.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/mem_clr.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/mem_dbg.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/cversion.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/ex_data.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/tmdiff.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/cpt_err.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/ebcdic.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/uid.c
.
.
.
.
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/dsa/
dsa_vrf.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/ripemd/
rmd_dgst.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/ripemd/
rmd_one.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/evp/
m_ripemd.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/bf/
bf_skey.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/bf/bf_ecb.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/bf/bf_enc.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/bf/
bf_cfb64.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/bf/
bf_ofb64.c
make: *** No rule to make target  out/apps/openssl/armeabi/libdl.so
, needed by  out/apps/openssl/armeabi/libcrypto.so . Stop.
j...@jiss:/android-ndk-r3$



I've realized that the problem comes from  the Android.mk from the
crypto/ folder at the end :


ifneq ($(TARGET_SIMULATOR),true)
        LOCAL_SHARED_LIBRARIES += libdl
endif
.
.
.
include $(BUILD_SHARED_LIBRARY)


And when I try to comment

#ifneq ($(TARGET_SIMULATOR),true)
#       LOCAL_SHARED_LIBRARIES += libdl
#endif


Here are the errors I get :


.
.
.
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/dsa/
dsa_vrf.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/ripemd/
rmd_dgst.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/ripemd/
rmd_one.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/evp/
m_ripemd.c
SharedLibrary  : libcrypto.so
out/apps/openssl/armeabi/objs/crypto/aes/aes_ecb.o: In function
`AES_ecb_encrypt':
/android-ndk-r3/apps/openssl/project/jni/crypto/aes/aes_ecb.c:71:
undefined reference to `AES_decrypt'
/android-ndk-r3/apps/openssl/project/jni/crypto/aes/aes_ecb.c:69:
undefined reference to `AES_encrypt'
out/apps/openssl/armeabi/objs/crypto/aes/aes_cbc.o: In function
`AES_cbc_encrypt':
/android-ndk-r3/apps/openssl/project/jni/crypto/aes/aes_cbc.c:95:
undefined reference to `AES_decrypt'
/android-ndk-r3/apps/openssl/project/jni/crypto/aes/aes_cbc.c:104:
undefined reference to `AES_decrypt'
.
.
.
.
out/apps/openssl/armeabi/objs/crypto/sha/sha512.o: In function
`SHA512_Final':
/android-ndk-r3/apps/openssl/project/jni/crypto/sha/sha512.c:131:
undefined reference to `sha512_block_data_order'
/android-ndk-r3/apps/openssl/project/jni/crypto/sha/sha512.c:106:
undefined reference to `sha512_block_data_order'
collect2: ld returned 1 exit status
make: *** [out/apps/openssl/armeabi/libcrypto.so] Error 1
j...@jiss:/android-ndk-r3$



That's all.... for the error.....


I would also like to use ECDH, ECDSA and EC, so I tried to add :

        ecdh/ech_err.c \
        ecdh/ech_key.c \
        ecdh/ech_lib.c \
        ecdh/ech_ossl.c \
        engine/tb_ecdh.c


to openssl/crypto/Android.mk

and commented all the LOCAL_CFLAGS concercing ECDH, ECDSA etc... in
the openssl/apps/Android.mk , /openssl/android-config.mk


But I got this error :

.
.
.
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/dso/
dso_null.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/dso/
dso_openssl.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/dso/
dso_win32.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/dso/
dso_vms.c
Compile thumb  : crypto <= apps/openssl/project/jni/crypto/ec/ec_lib.c
In file included from apps/openssl/project/jni/crypto/ec/ec_lcl.h:76,
                 from apps/openssl/project/jni/crypto/ec/ec_lib.c:69:
apps/openssl/project/jni/crypto/../include/openssl/ec.h:78:2: error:
#error EC is disabled.
make: *** [out/apps/openssl/armeabi/objs/crypto/ec/ec_lib.o] Error 1
j...@jiss:/android-ndk-r3$


That's it.....


I beg you to help me :( . I really need to use Elliptic Curve and
advanced SSL features for my internship, and these features were just
erased Android. :(


Thank you very much.

Regards,

Jiss


PS : here are the files I used, if you can take a look :
http://jiss33.free.fr/OpenSSL/


-- 

2. How to retrieve log levels in Java ?

Hi,

  How do I retrieve a System property in android Java application ?
Example I want to get the value of "ro.debuggable".  I tried
System.getProperty("ro.debuggable") and it is returning null.

Thanks!

-- 

3. Problems with span and onclick events

4. Question about registerReceiver

5. How to Play Mpeg2 Format Video

6. Is SPP supported by Android BT API?

7. Fwd: [blrdroid] s please help me with these issues