Click here to Skip to main content
15,913,669 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Thread Pin
David Crow18-Feb-09 3:28
David Crow18-Feb-09 3:28 
GeneralRe: Thread Pin
Luc Pattyn18-Feb-09 3:37
sitebuilderLuc Pattyn18-Feb-09 3:37 
GeneralRe: Thread Pin
Arman S.18-Feb-09 2:17
Arman S.18-Feb-09 2:17 
QuestionProblem with Array of char* Pin
error140818-Feb-09 0:05
error140818-Feb-09 0:05 
AnswerRe: Problem with Array of char* Pin
Sarath C18-Feb-09 0:15
Sarath C18-Feb-09 0:15 
AnswerRe: Problem with Array of char* Pin
«_Superman_»18-Feb-09 0:40
professional«_Superman_»18-Feb-09 0:40 
AnswerRe: Problem with Array of char* Pin
CPallini18-Feb-09 0:44
mveCPallini18-Feb-09 0:44 
GeneralRe: Problem with Array of char* Pin
error140818-Feb-09 1:16
error140818-Feb-09 1:16 
Ok look, here is the full function (that I did NOT write myself) which should work correct, but I think >>I<< do something NOT correct.
Its a tokenizer for char-strings

int strtoken(char *str, char *separator, char *token[])
	{
		int i = 0;

		token[0] = strtok(str, separator); //This line crashes

		while ( token[i] ) 
		{
			i++;
			token[i] = strtok(NULL, separator);
		}
		return ( i );
	}


And I call it that way atm:

char *token[256]; //I think that is an array of char*, isn't it?
for(int i = 0; i < 256; i++)
{
    token[i] = '\0';
}
Helper::instance()->strtoken(name, ".", token);


name is a char* e.g. "system.fullscreen"
GeneralRe: Problem with Array of char* Pin
CPallini18-Feb-09 1:56
mveCPallini18-Feb-09 1:56 
GeneralRe: Problem with Array of char* Pin
error140818-Feb-09 2:10
error140818-Feb-09 2:10 
GeneralRe: Problem with Array of char* Pin
CPallini18-Feb-09 2:28
mveCPallini18-Feb-09 2:28 
GeneralRe: Problem with Array of char* Pin
error140818-Feb-09 2:40
error140818-Feb-09 2:40 
GeneralRe: Problem with Array of char* Pin
CPallini18-Feb-09 3:10
mveCPallini18-Feb-09 3:10 
GeneralRe: Problem with Array of char* Pin
error140818-Feb-09 3:13
error140818-Feb-09 3:13 
GeneralRe: Problem with Array of char* Pin
CPallini18-Feb-09 3:18
mveCPallini18-Feb-09 3:18 
GeneralRe: Problem with Array of char* Pin
Arman S.18-Feb-09 2:03
Arman S.18-Feb-09 2:03 
QuestionRe: Problem with Array of char* Pin
David Crow18-Feb-09 3:19
David Crow18-Feb-09 3:19 
AnswerRe: Problem with Array of char* Pin
error140818-Feb-09 5:25
error140818-Feb-09 5:25 
GeneralRe: Problem with Array of char* Pin
David Crow18-Feb-09 5:30
David Crow18-Feb-09 5:30 
GeneralRe: Problem with Array of char* Pin
error140818-Feb-09 6:00
error140818-Feb-09 6:00 
GeneralRe: Problem with Array of char* Pin
David Crow18-Feb-09 6:06
David Crow18-Feb-09 6:06 
GeneralRe: Problem with Array of char* Pin
ilostmyid218-Feb-09 19:32
professionalilostmyid218-Feb-09 19:32 
QuestionHow to change the column order or position? Pin
mikert_200817-Feb-09 23:53
mikert_200817-Feb-09 23:53 
AnswerRe: How to change the column order or position? Pin
David Crow18-Feb-09 3:21
David Crow18-Feb-09 3:21 
Questionsaving list control data in a string Pin
brucewayn17-Feb-09 23:48
brucewayn17-Feb-09 23:48 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.