bladox.com Forum Index bladox.com
Turbo SIM Toolkit Adapter Forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

emalloc fail?

 
Post new topic   Reply to topic    bladox.com Forum Index -> Development
View previous topic :: View next topic  
Author Message
jbladox



Joined: 29 Jul 2008
Posts: 24

PostPosted: Thu Jul 16, 2009 12:38 pm    Post subject: emalloc fail? Reply with quote

Hello,

Since there is only 4 KB of EEPROM available, obviously there is an upper limit to how much memory one can emalloc. What does emalloc return if it fails to allocate the requested memory? Is it NULL like regular malloc, or another error code? Or does it crap out?

Also, does re-flashing a TSIM or TLITE recover all the "leaked" memory?

Thanks,
J
Back to top
View user's profile Send private message
jbladox



Joined: 29 Jul 2008
Posts: 24

PostPosted: Thu Jul 16, 2009 5:14 pm    Post subject: Reply with quote

I've found the answers to my questions.

emalloc returns 0 (NULL) on fail, and reports a perror in debug.

All "leaked" memory is reclaimed on a reflash of the TLite/SIM.
I was just worried about bricking my turbo tools.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    bladox.com Forum Index -> Development All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group