Click here to Skip to main content
12,882,397 members (25,502 online)

ATL / WTL / STL

 
GeneralRe: TCP blocking -vs- CAsyncSocket -vs- Win32 API Pin
pasztorpisti28-Dec-12 3:37
memberpasztorpisti28-Dec-12 3:37 
GeneralRe: TCP blocking -vs- CAsyncSocket -vs- Win32 API Pin
bkelly1327-Dec-12 8:22
memberbkelly1327-Dec-12 8:22 
GeneralRe: TCP blocking -vs- CAsyncSocket -vs- Win32 API Pin
pasztorpisti27-Dec-12 14:02
memberpasztorpisti27-Dec-12 14:02 
GeneralRe: TCP blocking -vs- CAsyncSocket -vs- Win32 API Pin
SoMad27-Dec-12 14:51
memberSoMad27-Dec-12 14:51 
GeneralRe: TCP blocking -vs- CAsyncSocket -vs- Win32 API Pin
bkelly1328-Dec-12 3:13
memberbkelly1328-Dec-12 3:13 
GeneralRe: TCP blocking -vs- CAsyncSocket -vs- Win32 API Pin
pasztorpisti28-Dec-12 5:06
memberpasztorpisti28-Dec-12 5:06 
Questioncalling virtual base class Pin
bkelly1314-Dec-12 7:36
memberbkelly1314-Dec-12 7:36 
AnswerRe: calling virtual base class Pin
pasztorpisti18-Dec-12 22:39
memberpasztorpisti18-Dec-12 22:39 
Here is the implementation of CAsyncSocket::OnAccept():
void CAsyncSocket::OnAccept(int /*nErrorCode*/)
{
}

As you see it doesn't count whether you call it or not but in my opinion its always better to upcall base class methods when you are not sure what to do and the upcall doesn't do any harmful thing to your code. In this case its unlikely that MS changes the implementation of such a core class but generally when you use others' classes as a baseclass its better not to build anything on assumptions. Imagine what happens if you refactor your socket code and you change the baseclass of your socket class from CAsyncSocket to another socket class of yours that does something meaningful in OnAccept()... So here I recommend the upcall as I think its a good practice.
AnswerRe: calling virtual base class Pin
Albert Holguin19-Dec-12 7:22
memberAlbert Holguin19-Dec-12 7:22 
GeneralThe reason for the question Pin
bkelly1319-Dec-12 15:51
memberbkelly1319-Dec-12 15:51 
GeneralRe: The reason for the question Pin
Richard MacCutchan19-Dec-12 23:06
mvpRichard MacCutchan19-Dec-12 23:06 
GeneralRe: The reason for the question Pin
bkelly1321-Dec-12 6:11
memberbkelly1321-Dec-12 6:11 
Questioncannot add control variable to checkbox Pin
bkelly1314-Dec-12 3:07
memberbkelly1314-Dec-12 3:07 
AnswerRe: cannot add control variable to checkbox Pin
Richard MacCutchan14-Dec-12 3:36
mvpRichard MacCutchan14-Dec-12 3:36 
GeneralRe: cannot add control variable to checkbox Pin
bkelly1314-Dec-12 5:18
memberbkelly1314-Dec-12 5:18 
Questiondetect multiple instances of an application Pin
bkelly1310-Dec-12 12:28
memberbkelly1310-Dec-12 12:28 
AnswerRe: detect multiple instances of an application Pin
Pete O'Hanlon10-Dec-12 12:31
protectorPete O'Hanlon10-Dec-12 12:31 
GeneralRe: detect multiple instances of an application Pin
bkelly1310-Dec-12 13:38
memberbkelly1310-Dec-12 13:38 
AnswerRe: detect multiple instances of an application Pin
H.Brydon31-Dec-12 20:09
memberH.Brydon31-Dec-12 20:09 
QuestionOpen file in basic MFC app Pin
bkelly135-Dec-12 14:45
memberbkelly135-Dec-12 14:45 
AnswerRe: Open file in basic MFC app Pin
Richard MacCutchan5-Dec-12 21:24
mvpRichard MacCutchan5-Dec-12 21:24 
GeneralRe: Open file in basic MFC app Pin
bkelly139-Dec-12 11:36
memberbkelly139-Dec-12 11:36 
GeneralRe: Open file in basic MFC app Pin
Richard MacCutchan9-Dec-12 21:36
mvpRichard MacCutchan9-Dec-12 21:36 
Generalthe answer is Pin
bkelly139-Dec-12 12:25
memberbkelly139-Dec-12 12:25 
QuestionHow To Use Macro In dsp file(VC6.0 *.dsp file) Pin
yingkou27-Nov-12 14:37
memberyingkou27-Nov-12 14:37 

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.


Advertise | Privacy | Mobile
Web02 | 2.8.170422.1 | Last Updated 22 Apr 2017
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid