Click here to Skip to main content
15,921,156 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Getting message map for dynamic controls Pin
Nitron14-Apr-04 5:57
Nitron14-Apr-04 5:57 
GeneralRe: Getting message map for dynamic controls Pin
PJ Arends14-Apr-04 6:04
professionalPJ Arends14-Apr-04 6:04 
GeneralRe: freeing a char * in Ansi C Pin
Tim Smith14-Apr-04 3:56
Tim Smith14-Apr-04 3:56 
GeneralRe: freeing a char * in Ansi C Pin
John M. Drescher14-Apr-04 4:27
John M. Drescher14-Apr-04 4:27 
GeneralRe: freeing a char * in Ansi C Pin
kfaday14-Apr-04 4:36
kfaday14-Apr-04 4:36 
GeneralRe: freeing a char * in Ansi C Pin
toxcct14-Apr-04 4:18
toxcct14-Apr-04 4:18 
GeneralRe: freeing a char * in Ansi C Pin
Prakash Nadar14-Apr-04 4:42
Prakash Nadar14-Apr-04 4:42 
GeneralRe: freeing a char * in Ansi C Pin
Paul Ranson14-Apr-04 4:48
Paul Ranson14-Apr-04 4:48 
Your code as written seems to work as intended. So I'm not sure what your problem is unless you're walking over the end of the buffer. It would be better to write your scanf line thus,
scanf ( "%h50s", nomarchc ) ;

Where the width specifier is always one less than the size of the allocated buffer to allow for the trailing null.

Paul
GeneralRe: freeing a char * in Ansi C Pin
kfaday14-Apr-04 4:54
kfaday14-Apr-04 4:54 
GeneralApplication Error ! Pin
Anonymous14-Apr-04 3:11
Anonymous14-Apr-04 3:11 
GeneralRe: Application Error ! Pin
Cedric Moonen14-Apr-04 3:20
Cedric Moonen14-Apr-04 3:20 
GeneralRe: Application Error ! Pin
Anonymous14-Apr-04 3:30
Anonymous14-Apr-04 3:30 
GeneralRe: Application Error ! Pin
Maximilien14-Apr-04 3:53
Maximilien14-Apr-04 3:53 
GeneralRe: Application Error ! Pin
Nitron14-Apr-04 4:37
Nitron14-Apr-04 4:37 
QuestionVS 6.0 or VS 7.0?? Pin
Demian Panello14-Apr-04 3:10
Demian Panello14-Apr-04 3:10 
AnswerRe: VS 6.0 or VS 7.0?? Pin
David Crow14-Apr-04 3:33
David Crow14-Apr-04 3:33 
GeneralRe: VS 6.0 or VS 7.0?? Pin
Demian Panello14-Apr-04 4:06
Demian Panello14-Apr-04 4:06 
GeneralRe: VS 6.0 or VS 7.0?? Pin
basementman14-Apr-04 4:16
basementman14-Apr-04 4:16 
AnswerRe: VS 6.0 or VS 7.0?? Pin
_moved14-Apr-04 3:57
_moved14-Apr-04 3:57 
AnswerRe: VS 6.0 or VS 7.0?? Pin
Tim Smith14-Apr-04 3:59
Tim Smith14-Apr-04 3:59 
GeneralCListView Pin
packetlos14-Apr-04 2:27
packetlos14-Apr-04 2:27 
GeneralRe: CListView Pin
David Crow14-Apr-04 2:32
David Crow14-Apr-04 2:32 
GeneralRe: CListView Pin
packetlos14-Apr-04 3:01
packetlos14-Apr-04 3:01 
GeneralVisual c++ command line shelling Pin
mikewithersone14-Apr-04 2:16
mikewithersone14-Apr-04 2:16 
GeneralRe: Visual c++ command line shelling Pin
David Crow14-Apr-04 2:32
David Crow14-Apr-04 2:32 

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.