ios - Bad Access/Pointer Issue in Objective-C -


I've got the following bit code:

  byte * tokenaut = null; For (int i = 0; i & lt; saiff (takenout); i ++) {tokenaut [i * 2] = (tknt [i]> gt; 8); Tokenout [[i * 2] + 1] = (tunout [i] and 0x ff); }   

But when I try to update tokenout, it generates an EXC_BAD_ACCESS error when it runs I would be happy that someone can tell me what I am doing!

Thank you!

Trying

You are dereferencing a zero pointer

  whatever byte; Byte * Out Token = & whatever; // do the rest.   

Now there is a valid memory for you to type.

Except that you still have problems because you will write at the end of your variable. So maybe you wanted an array?

sizeof (outTkn) will return 1 (1 byte)

Comments

Popular posts from this blog

php - PDO bindParam() fatal error -

logging - How can I log both the Request.InputStream and Response.OutputStream traffic in my ASP.NET MVC3 Application for specific Actions? -

java - Why my included JSP file won't get processed correctly? -