Click here to Skip to main content
15,890,438 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
Questionerror C2248 : After converting to .net Pin
sheetal_064-Feb-07 18:09
sheetal_064-Feb-07 18:09 
QuestionPointer Math: Bad Code Generation (VS 7.0 and 8.0) Pin
Jeffrey Walton4-Feb-07 17:25
Jeffrey Walton4-Feb-07 17:25 
AnswerRe: Pointer Math: Bad Code Generation (VS 7.0 and 8.0) Pin
Stephen Hewitt4-Feb-07 17:53
Stephen Hewitt4-Feb-07 17:53 
GeneralRe: Pointer Math: Bad Code Generation (VS 7.0 and 8.0) Pin
Jeffrey Walton4-Feb-07 18:25
Jeffrey Walton4-Feb-07 18:25 
AnswerRe: Pointer Math: Bad Code Generation (VS 7.0 and 8.0) Pin
cmk4-Feb-07 18:03
cmk4-Feb-07 18:03 
GeneralRe: Pointer Math: Bad Code Generation (VS 7.0 and 8.0) Pin
Jeffrey Walton4-Feb-07 18:21
Jeffrey Walton4-Feb-07 18:21 
AnswerRe: Pointer Math: Bad Code Generation (VS 7.0 and 8.0) Pin
Stephen Hewitt4-Feb-07 18:30
Stephen Hewitt4-Feb-07 18:30 
GeneralRe: Pointer Math: Bad Code Generation (VS 7.0 and 8.0) Pin
Jeffrey Walton4-Feb-07 18:54
Jeffrey Walton4-Feb-07 18:54 
Hi Steve,

That was it - I did not want to cast away the PVOID on the File Mapping before adding the offset, but the compiler was complaining about the math...

Jeff

pNTHeader = reinterpret_cast< PIMAGE_NT_HEADERS >(
    (PBYTE)pcbMappedFile + pDOSHeader->e_lfanew );
if( pNTHeader->Signature != IMAGE_NT_SIGNATURE )
{
    std::cout << _T("Error - File is not PE Format") << std::endl;
    __leave;
}

QuestionDateAdd equivalent? Pin
nm_1144-Feb-07 16:41
nm_1144-Feb-07 16:41 
AnswerRe: DateAdd equivalent? Pin
David Crow4-Feb-07 17:22
David Crow4-Feb-07 17:22 
GeneralRe: DateAdd equivalent? Pin
nm_1144-Feb-07 17:44
nm_1144-Feb-07 17:44 
QuestionRe: DateAdd equivalent? Pin
David Crow5-Feb-07 4:56
David Crow5-Feb-07 4:56 
AnswerRe: DateAdd equivalent? Pin
nm_1145-Feb-07 13:43
nm_1145-Feb-07 13:43 
QuestionRe: DateAdd equivalent? Pin
David Crow6-Feb-07 3:10
David Crow6-Feb-07 3:10 
AnswerRe: DateAdd equivalent? Pin
nm_1146-Feb-07 11:58
nm_1146-Feb-07 11:58 
QuestionRe: DateAdd equivalent? Pin
David Crow6-Feb-07 15:18
David Crow6-Feb-07 15:18 
AnswerRe: DateAdd equivalent? Pin
nm_1146-Feb-07 15:59
nm_1146-Feb-07 15:59 
GeneralRe: DateAdd equivalent? Pin
David Crow6-Feb-07 16:09
David Crow6-Feb-07 16:09 
GeneralRe: DateAdd equivalent? Pin
nm_1146-Feb-07 16:35
nm_1146-Feb-07 16:35 
GeneralRe: DateAdd equivalent? Pin
David Crow7-Feb-07 2:35
David Crow7-Feb-07 2:35 
GeneralRe: DateAdd equivalent? Pin
nm_1147-Feb-07 13:37
nm_1147-Feb-07 13:37 
GeneralRe: DateAdd equivalent? Pin
David Crow7-Feb-07 16:44
David Crow7-Feb-07 16:44 
GeneralRe: DateAdd equivalent? Pin
nm_1148-Feb-07 12:06
nm_1148-Feb-07 12:06 
GeneralRe: DateAdd equivalent? Pin
David Crow8-Feb-07 16:55
David Crow8-Feb-07 16:55 
GeneralRe: DateAdd equivalent? Pin
nm_1148-Feb-07 19:02
nm_1148-Feb-07 19:02 

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.