Click here to Skip to main content
16,012,166 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: urgent help me Pin
Anonymous22-Jun-04 7:40
Anonymous22-Jun-04 7:40 
GeneralRe: urgent help me Pin
palbano22-Jun-04 6:56
palbano22-Jun-04 6:56 
Generalglobal variables Pin
dolph_loe22-Jun-04 5:20
dolph_loe22-Jun-04 5:20 
GeneralRe: global variables Pin
Johan Rosengren22-Jun-04 5:28
Johan Rosengren22-Jun-04 5:28 
GeneralRe: global variables Pin
dolph_loe22-Jun-04 6:42
dolph_loe22-Jun-04 6:42 
GeneralRe: global variables Pin
Johan Rosengren22-Jun-04 8:29
Johan Rosengren22-Jun-04 8:29 
GeneralRe: global variables Pin
jmkhael22-Jun-04 5:29
jmkhael22-Jun-04 5:29 
GeneralRe: global variables Pin
David Crow22-Jun-04 5:53
David Crow22-Jun-04 5:53 
Have you single-stepped through the code to see which statement is writing to the memory address in question? Consider the following:

1) char c1 = 'D'; // 0x0012e7d8
2) char c2 = 'C'; // 0x0012e7d4
3) int *i3 = (int *) &c2; // point to the address of c2
4) *i3 = 1234567; // change the value at c2's address, thus stepping on c1
We never directly wrote to c1 or c2, but c1 got changed indirectly. Setting a breakpoint on the first two statements would not show you anything as the "damage" does not happen until the fourth statement. Make sense?


"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen


GeneralRe: global variables Pin
dolph_loe22-Jun-04 6:59
dolph_loe22-Jun-04 6:59 
GeneralRe: global variables Pin
Henry miller22-Jun-04 8:15
Henry miller22-Jun-04 8:15 
GeneralModeless Dialogs & Z order Pin
Mark Kinsley22-Jun-04 4:47
Mark Kinsley22-Jun-04 4:47 
GeneralRe: Modeless Dialogs & Z order Pin
V.22-Jun-04 4:57
professionalV.22-Jun-04 4:57 
GeneralRe: Modeless Dialogs & Z order Pin
PJ Arends22-Jun-04 5:26
professionalPJ Arends22-Jun-04 5:26 
GeneralRe: Modeless Dialogs & Z order Pin
Mark Kinsley22-Jun-04 5:49
Mark Kinsley22-Jun-04 5:49 
GeneralRe: Modeless Dialogs & Z order Pin
PJ Arends22-Jun-04 10:12
professionalPJ Arends22-Jun-04 10:12 
GeneralRe: Modeless Dialogs & Z order Pin
Mark Kinsley22-Jun-04 21:36
Mark Kinsley22-Jun-04 21:36 
GeneralModeless Dialogs Pin
si_6922-Jun-04 4:10
si_6922-Jun-04 4:10 
GeneralRe: Modeless Dialogs Pin
Johan Rosengren22-Jun-04 5:21
Johan Rosengren22-Jun-04 5:21 
GeneralRe: Modeless Dialogs Pin
David Crow22-Jun-04 5:59
David Crow22-Jun-04 5:59 
GeneralRe: Modeless Dialogs Pin
si_6923-Jun-04 1:17
si_6923-Jun-04 1:17 
GeneralRe: Modeless Dialogs Pin
David Crow23-Jun-04 2:04
David Crow23-Jun-04 2:04 
GeneralRe: Modeless Dialogs Pin
si_6923-Jun-04 2:28
si_6923-Jun-04 2:28 
GeneralRe: Modeless Dialogs Pin
David Crow23-Jun-04 2:40
David Crow23-Jun-04 2:40 
Generaldouble and float problem Pin
NMiceli22-Jun-04 3:50
NMiceli22-Jun-04 3:50 
GeneralRe: double and float problem Pin
Tim Smith22-Jun-04 4:01
Tim Smith22-Jun-04 4:01 

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.