Click here to Skip to main content
15,844,009 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: [C]Problem in creating a random string Pin
k505427-Oct-16 5:47
mvek505427-Oct-16 5:47 
GeneralRe: [C]Problem in creating a random string Pin
Richard MacCutchan27-Oct-16 5:55
mveRichard MacCutchan27-Oct-16 5:55 
AnswerRe: [C]Problem in creating a random string Pin
Jochen Arndt27-Oct-16 3:35
professionalJochen Arndt27-Oct-16 3:35 
AnswerRe: [C]Problem in creating a random string Pin
leon de boer27-Oct-16 4:43
leon de boer27-Oct-16 4:43 
SuggestionRe: [C]Problem in creating a random string Pin
David Crow27-Oct-16 5:48
David Crow27-Oct-16 5:48 
GeneralRe: [C]Problem in creating a random string Pin
Daniel Pfeffer27-Oct-16 6:11
professionalDaniel Pfeffer27-Oct-16 6:11 
AnswerRe: [C]Problem in creating a random string Pin
Krishnakumartg27-Oct-16 21:18
Krishnakumartg27-Oct-16 21:18 
GeneralRe: [C]Problem in creating a random string Pin
k505428-Oct-16 5:59
mvek505428-Oct-16 5:59 
Only as long as Range < 100.

Which also brings up the question of what happens if Range < 0. It might be better to use size_t for Range and your loop variable i. You should probably check the return value of malloc() too, just to be safe.

Oh. And you're leaking the results of ReturnRandomString(). There should probably be a free() when you are done with it.

PraiseRe: [C]Problem in creating a random string Pin
Krishnakumartg30-Oct-16 19:50
Krishnakumartg30-Oct-16 19:50 
QuestionRe: [C]Problem in creating a random string Pin
David Crow31-Oct-16 3:31
David Crow31-Oct-16 3:31 
QuestionUsing COM in DLL called by .Net application Pin
Leif Simon Goodwin26-Oct-16 4:02
Leif Simon Goodwin26-Oct-16 4:02 
AnswerRe: Using COM in DLL called by .Net application Pin
Richard Deeming26-Oct-16 4:11
mveRichard Deeming26-Oct-16 4:11 
PraiseSOLVED Pin
Leif Simon Goodwin9-Nov-16 6:32
Leif Simon Goodwin9-Nov-16 6:32 
AnswerRe: Using COM in DLL called by .Net application Pin
«_Superman_»26-Oct-16 21:47
professional«_Superman_»26-Oct-16 21:47 
GeneralRe: Using COM in DLL called by .Net application Pin
Leif Simon Goodwin8-Nov-16 21:53
Leif Simon Goodwin8-Nov-16 21:53 
QuestionError in returning array of int as reference Pin
Korowai22-Oct-16 20:35
Korowai22-Oct-16 20:35 
AnswerRe: Error in returning array of int as reference Pin
Graham Breach22-Oct-16 22:46
Graham Breach22-Oct-16 22:46 
GeneralRe: Error in returning array of int as reference Pin
Korowai22-Oct-16 23:41
Korowai22-Oct-16 23:41 
GeneralRe: Error in returning array of int as reference Pin
Midi_Mick23-Oct-16 0:12
professionalMidi_Mick23-Oct-16 0:12 
GeneralRe: Error in returning array of int as reference Pin
Korowai23-Oct-16 3:39
Korowai23-Oct-16 3:39 
GeneralRe: Error in returning array of int as reference Pin
leon de boer23-Oct-16 5:24
leon de boer23-Oct-16 5:24 
GeneralRe: Error in returning array of int as reference Pin
Korowai23-Oct-16 9:11
Korowai23-Oct-16 9:11 
GeneralRe: Error in returning array of int as reference Pin
Korowai23-Oct-16 9:26
Korowai23-Oct-16 9:26 
QuestionRe: Error in returning array of int as reference Pin
David Crow23-Oct-16 16:26
David Crow23-Oct-16 16:26 
AnswerRe: Error in returning array of int as reference Pin
Joe Woodbury24-Oct-16 15:07
professionalJoe Woodbury24-Oct-16 15:07 

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.