Click here to Skip to main content
15,900,724 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Remote Office Automation Pin
Michael P Butler23-Oct-04 9:00
Michael P Butler23-Oct-04 9:00 
GeneralTroubling creating object Pin
AmorphousP22-Oct-04 7:04
AmorphousP22-Oct-04 7:04 
GeneralRe: Troubling creating object Pin
David Crow22-Oct-04 7:40
David Crow22-Oct-04 7:40 
GeneralRe: Troubling creating object Pin
AmorphousP22-Oct-04 9:37
AmorphousP22-Oct-04 9:37 
GeneralRe: Troubling creating object Pin
Maximilien22-Oct-04 9:51
Maximilien22-Oct-04 9:51 
GeneralRe: Troubling creating object Pin
AmorphousP22-Oct-04 10:34
AmorphousP22-Oct-04 10:34 
GeneralRe: Troubling creating object Pin
David Crow22-Oct-04 9:53
David Crow22-Oct-04 9:53 
GeneralRe: Troubling creating object Pin
AmorphousP22-Oct-04 10:29
AmorphousP22-Oct-04 10:29 
Actually the object is getting created dynamically now and I tried stepping through the constructor of CDns.

DnsSocket = new CSocket;<br />
	SockStatus = TRUE;<br />
	if (DnsSocket)<br />
	{<br />
		if (!DnsSocket->Create(0, SOCK_DGRAM, 0))

It's asserting on Create. It's here that it gives an access violation. The ASSERT that fires it is

ASSERT(CAsyncSocket::LookupHandle(hSocket, bDead) == NULL);

in the file sockcore.cpp


DavidCrow wrote:
AmorphousP wrote:
CDns* DnsCl;
This is the part when it is created on the stack. It doesn't assert but now when I call a public member fuction of the CDns class like

DnsCl->GetSMTPAddress(domain);
...
causes an 'access violation'.

I'm not surprised. How is this working without the new operator being called?


It was actually a desperate attempt to get the work done although wasn't a very logical choice.
GeneralRe: Troubling creating object Pin
dharani26-Oct-04 22:44
dharani26-Oct-04 22:44 
GeneralRe: Troubling creating object Pin
AmorphousP27-Oct-04 9:51
AmorphousP27-Oct-04 9:51 
GeneralAbstract member functions - strange phenomenon open to discussion: Pin
Nick Nougat22-Oct-04 6:54
Nick Nougat22-Oct-04 6:54 
GeneralRe: Abstract member functions - strange phenomenon open to discussion: Pin
Roger Allen22-Oct-04 7:13
Roger Allen22-Oct-04 7:13 
GeneralRe: Abstract member functions - strange phenomenon open to discussion: Pin
Nick Nougat22-Oct-04 7:58
Nick Nougat22-Oct-04 7:58 
QuestionHow can I programmatically install a visual C++ add-in for visual C++? Pin
Behzad Ebrahimi22-Oct-04 5:56
Behzad Ebrahimi22-Oct-04 5:56 
GeneralPeek stdin Pin
peterchen22-Oct-04 5:50
peterchen22-Oct-04 5:50 
GeneralRe: Peek stdin Pin
David Crow22-Oct-04 6:04
David Crow22-Oct-04 6:04 
GeneralPlease help me with MFC Dialogs Pin
Member 214873122-Oct-04 5:22
Member 214873122-Oct-04 5:22 
GeneralRe: Please help me with MFC Dialogs Pin
David Crow22-Oct-04 5:33
David Crow22-Oct-04 5:33 
GeneralRe: Please help me with MFC Dialogs Pin
Member 214873122-Oct-04 5:34
Member 214873122-Oct-04 5:34 
GeneralRe: Please help me with MFC Dialogs Pin
David Crow22-Oct-04 5:37
David Crow22-Oct-04 5:37 
GeneralRe: Please help me with MFC Dialogs Pin
Buyer122-Oct-04 5:42
sussBuyer122-Oct-04 5:42 
GeneralRe: Please help me with MFC Dialogs Pin
David Crow22-Oct-04 5:46
David Crow22-Oct-04 5:46 
GeneralRe: Please help me with MFC Dialogs Pin
Buyer122-Oct-04 5:53
sussBuyer122-Oct-04 5:53 
GeneralRe: Please help me with MFC Dialogs Pin
David Crow22-Oct-04 5:57
David Crow22-Oct-04 5:57 
GeneralRe: Please help me with MFC Dialogs Pin
Buyer122-Oct-04 6:10
sussBuyer122-Oct-04 6:10 

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.