Android app (with felix) crashes with LinearAlloc exceeded capacity

Posted by user1106000 on Stack Overflow See other posts from Stack Overflow or by user1106000
Published on 2011-12-19T14:00:11Z Indexed on 2012/03/20 11:30 UTC
Read the original article Hit count: 478

Filed under:
|
|
|

I am running apache felix and an osgi app on android (3.2). This works pretty well so far, but I have rather large chunks of data to load into the application (osgi bundles). The problem with that is that when I load the biggest chunk of data I get

LinearAlloc exceeded capacity

The error seems to come from

LinearAlloc.c

\#define DEFAULT_MAX_LENGTH  (4*1024*1024)

 if (nextOffset > pHdr->mapLength) {
    /*
     * We don't have to abort here.  We could fall back on the system
     * malloc(), and have our "free" call figure out what to do.  Only
     * works if the users of these functions actually free everything
     * they allocate.
     */
    LOGE("LinearAlloc exceeded capacity, last=%d\n", (int) size);
    dvmAbort();
}

afaik in 3.2/4.x it is even 8*1024*1024, but I still hit that limit. I'm looking to get better insight on what causes this problem and how I might possibly be able to fix it. Any help would be appreciated.

© Stack Overflow or respective owner

Related posts about android

Related posts about osgi