Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8932671
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T09:21:57+00:00 2026-06-15T09:21:57+00:00

I am working on a cross platform application for Android and IOS. When I

  • 0

I am working on a cross platform application for Android and IOS. When I try to get a .json file located in assets folder like below

const char * genrefile =   CCFileUtils::sharedFileUtils()->fullPathFromRelativePath("genres.json");
CCLog( " %s ---------- genrefile ---------", genrefile);

size_t size;
unsigned char * charbuffer = CCFileUtils::sharedFileUtils()->getFileData(genrefile, "rb", 0);

control comes out of the application with following stack trace

11-28 16:53:51.319: INFO/DEBUG(13089): *** *** *** *** *** *** *** *** *** *** *** *** 

*** *** *** ***
11-28 16:53:51.319: INFO/DEBUG(13089): Build fingerprint: 'samsung/GT-P7300/GT-P7300:3.1/HMJ37/XWKI3:user/release-keys'
11-28 16:53:51.319: INFO/DEBUG(13089): pid: 13255, tid: 13263  >>> com.humit <<<
11-28 16:53:51.319: INFO/DEBUG(13089): signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 00000000
11-28 16:53:51.319: INFO/DEBUG(13089):  r0 000c4780  r1 00218274  r2 00000000  r3 00000000
11-28 16:53:51.319: INFO/DEBUG(13089):  r4 80f80524  r5 00000000  r6 5c160c18  r7 52b1df2c
11-28 16:53:51.319: INFO/DEBUG(13089):  r8 5c160b70  r9 52b1df24  10 52b1df10  fp 00000000
11-28 16:53:51.319: INFO/DEBUG(13089):  ip afc03108  sp 5c160488  lr 80d5f981  pc 80d5f516  cpsr 40000030
11-28 16:53:51.319: INFO/DEBUG(13089):  d0  c449c9bc448522eb  d1  447a0000c425612c
11-28 16:53:51.319: INFO/DEBUG(13089):  d2  46fffe00c47a0000  d3  c1e00000ffffffe4
11-28 16:53:51.319: INFO/DEBUG(13089):  d4  c1dec600c1dac600  d5  4110000000000009
11-28 16:53:51.319: INFO/DEBUG(13089):  d6  3f800000ffffffe0  d7  4485261dbf800000
11-28 16:53:51.319: INFO/DEBUG(13089):  d8  0000000000000000  d9  0000000000000000
11-28 16:53:51.319: INFO/DEBUG(13089):  d10 0000000000000000  d11 0000000000000000
11-28 16:53:51.319: INFO/DEBUG(13089):  d12 0000000000000000  d13 0000000000000000
11-28 16:53:51.319: INFO/DEBUG(13089):  d14 0000000000000000  d15 0000000000000000
11-28 16:53:51.319: INFO/DEBUG(13089):  scr 60000012
11-28 16:53:51.409: DEBUG/Finsky(2593): [1] 5.onFinished: Installation state replication succeeded.
11-28 16:53:51.459: INFO/DEBUG(13089):          #00  pc 0015f516  /data/data/com.humit/lib/libgame.so (_ZN7cocos2d11CCFileUtils18getFileDataFromZipEPKcS2_Pm)
11-28 16:53:51.469: INFO/DEBUG(13089):          #01  pc 0015f97c  /data/data/com.humit/lib/libgame.so (_ZN7cocos2d11CCFileUtils11getFileDataEPKcS2_Pm)
11-28 16:53:51.469: INFO/DEBUG(13089):          #02  pc 000f0fe2  /data/data/com.humit/lib/libgame.so (_ZN17SelectGenreScreen9loadgenreEv)
11-28 16:53:51.469: INFO/DEBUG(13089):          #03  pc 000f11fa  /data/data/com.humit/lib/libgame.so (_ZN17SelectGenreScreen4initEv)
11-28 16:53:51.469: INFO/DEBUG(13089):          #04  pc 000f0934  /data/data/com.humit/lib/libgame.so (_ZN17SelectGenreScreen6createEv)
11-28 16:53:51.469: INFO/DEBUG(13089):          #05  pc 000f0b1c  /data/data/com.humit/lib/libgame.so (_ZN17SelectGenreScreen5sceneEv)
11-28 16:53:51.469: INFO/DEBUG(13089):          #06  pc 000f6c24  /data/data/com.humit/lib/libgame.so (_ZN18RandomPlayerScreen22onHttpRequestCompletedEPN7cocos2d6CCNodeEPv)
11-28 16:53:51.469: INFO/DEBUG(13089):          #07  pc 001bd1fa  /data/data/com.humit/lib/libgame.so (_ZN7cocos2d9extension12CCHttpClient25dispatchResponseCallbacksEf)
11-28 16:53:51.469: INFO/DEBUG(13089):          #08  pc 000f8a72  /data/data/com.humit/lib/libgame.so (_ZN7cocos2d7CCTimer6updateEf)
11-28 16:53:51.469: INFO/DEBUG(13089):          #09  pc 000fe49e  /data/data/com.humit/lib/libgame.so (_ZN7cocos2d11CCScheduler6updateEf)
11-28 16:53:51.469: INFO/DEBUG(13089):          #10  pc 001288c0  /data/data/com.humit/lib/libgame.so (_ZN7cocos2d10CCDirector9drawSceneEv)
11-28 16:53:51.469: INFO/DEBUG(13089):          #11  pc 00129ec0  /data/data/com.humit/lib/libgame.so (_ZN7cocos2d21CCDisplayLinkDirector8mainLoopEv)
11-28 16:53:51.469: INFO/DEBUG(13089):          #12  pc 00165a08  /data/data/com.humit/lib/libgame.so (Java_org_cocos2dx_lib_Cocos2dxRenderer_nativeRender)
11-28 16:53:51.469: INFO/DEBUG(13089):          #13  pc 00011d34  /system/lib/libdvm.so
11-28 16:53:51.469: INFO/DEBUG(13089):          #14  pc 000411a2  /system/lib/libdvm.so (dvmCallJNIMethod_staticNoRef)
11-28 16:53:51.469: INFO/DEBUG(13089): libc base address: aff00000
11-28 16:53:51.469: INFO/DEBUG(13089): code around pc:
11-28 16:53:51.469: INFO/DEBUG(13089): 80d5f4f4 4c5b44a5 9007447c 92059106 4b599304 
11-28 16:53:51.469: INFO/DEBUG(13089): 80d5f504 681b58e3 230093a1 2300931f 9b04931e 
11-28 16:53:51.469: INFO/DEBUG(13089): 80d5f514 601a2200 2b009b06 e07dd100 2b009b05 
11-28 16:53:51.469: INFO/DEBUG(13089): 80d5f524 e07bd100 781b9b06 d1002b00 9b06e078 
11-28 16:53:51.469: INFO/DEBUG(13089): 80d5f534 f01a1c18 1c03fef1 9b1e931e d1002b00 
11-28 16:53:51.469: INFO/DEBUG(13089): code around lr:
11-28 16:53:51.469: INFO/DEBUG(13089): 80d5f960 1c18447b ed52f16d ab091c04 f16d1c18 
11-28 16:53:51.469: INFO/DEBUG(13089): 80d5f970 1c02ed4e 9b009903 1c211c08 fdb8f7ff 
11-28 16:53:51.469: INFO/DEBUG(13089): 80d5f980 930a1c03 447b4b75 21651c18 ff9cf7fe 
11-28

getFileData(...) method in CCFileUtils class works fine to get images but not with other files. Help is greatly appreciated.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T09:21:58+00:00Added an answer on June 15, 2026 at 9:21 am

    Try this:

    unsigned long bufferSize = 0;
    unsigned char * charbuffer = CCFileUtils::sharedFileUtils()->getFileData(genrefile, "rb", &bufferSize );
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm working on a cross-platform application for which I would like to include Solaris/SPARC
I am working on a cross platform project in C++, under IOS and Android,
I'm working on an application that I need to be cross-platform. I'd like to
I'm currently working on a cross-platform application (Win/OSX/iOS) which has a C++ (with Boost)
I'm working on a cross platform C++ application for Windows, Mac OS X and
I am working on a cross platform mobile application using phonegap (html,javascript) problem is
I'm working on a C++ cross-platform OpenGL application (Windows, Linux and MacOS) and I
I'm working on a cross platform application in Java which currently works nicely on
I am working on a Cross-Platform open-source project. My application is going to support
I'm working on some cross-platform desktop application with heavy 2-D graphics. I use OpenGL

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.