473,563 Members | 2,696 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Socket.ReceiveF rom

why Socket.ReceiveF rom(byte[], ref EndPoint) and SendTo(byte[], ref
EndPoint) uses ref ? I know what ref means but why it has to use ref is the
question.

Thanks a lot,
Chang
Nov 16 '05 #1
1 2103
I think its an artefact from the original code. You should be able to find
the source to an implementation of the Berkeley Sockets Protocol online.

ok,
aq

"Chang" <no*****@thisad dress.com> wrote in message
news:%2******** ********@TK2MSF TNGP11.phx.gbl. ..
why Socket.ReceiveF rom(byte[], ref EndPoint) and SendTo(byte[], ref
EndPoint) uses ref ? I know what ref means but why it has to use ref is the question.

Thanks a lot,
Chang

Nov 16 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1683
by: Dan Rice | last post by:
Hello, Im trying to get the following working but it doesn't seem to receive anything. I have got the UdpClient class to receive data but unreliably and was told to use the Socket class directly. Here's the code: Dim lep As New IPEndPoint(IPAddress.Any, 0) Dim s As New Socket(AddressFamily.InterNetwork,
1
3066
by: Rolln_Thndr | last post by:
I'm vey new to network programing and have a few rather fundemental questions. I'm creating a very basic UDP proxy server and having a few issues regarding the sockets. Is it possible to change the properties of a socket WITHOUT closing it and creating a new one? Basically, I need to change the port of a bound socket, but the only way I...
2
1817
by: Richy Rich | last post by:
Hi, I've developed an application in C# which spawns a thread to receive datagrams. If I use the socket receive method, there are no problems when using the application under NT or XP. I recently moved over to using the UdpClient receive method. This was so I could record the IPEndPoint from
5
11665
by: Terry | last post by:
It's my understanding of UDP sockets that if there is a thread blocked on a "recvFrom()" call and other thread sends a UDP packet to some address, that if the machine on the other end isn't up, that the "recvFrom()" call should just continue blocking. Right? What I'm seeing is that when I send a packet to a particular address that is not...
10
12179
by: Jim H | last post by:
I have a UDP socket that sends out a request on a multicast socket and waits for a response. This client is not listening on a multicast IP but the local IP. The server (UNIX) responds to the sender's IP. Using debug files on the server I see the server receive the request from my application on my machine and I see the server send to the...
1
4397
by: Nuno Magalhaes | last post by:
Does the function below returns an UDP packet, for example, from the local machine? Why does it give me an error: "The best overloaded method match for ReceiveFrom... has some invalid arguments". Why this error? How can I receive a packet from a specific adapter, for example, my local machine? Is there a better way? This way won't work. The...
2
2264
by: eliss.carmine | last post by:
Hi, I have an application where a listener thread has a while loop that just calls Socket.ReceiveFrom over and over. When I close the app by clickin on the X, the process doesn't die because there is still this listener thread running. How do I terminate this thread as well? Thanks
0
3111
by: jkhan | last post by:
Hi! I have problem which I shown in title and below as well. I have a Form name as Cancelation. The clientThread2() method is called on Form Load if I Close the Form and want to reload then the above error is generated as I tried to close, shutdown etc for closing the socket or thread but useless. Any one have idea about it. The above...
1
2692
by: ssherm01 | last post by:
I'm using MS VS C++ .NET. I've written a multicast test utility that can send IGMP packets for a user specified group address. As well, it can send and receive UDP packets for a specified multicast group. I'm using the Sockets Class methods for sending and receiving packets. One area I'm having problems with is recieving IGMP packets on the...
0
1492
by: Johan | last post by:
Why is the parameter remoteEP of the function Socket.ReceiveFrom() a ref parameter and not an out parameter? http://msdn2.microsoft.com/en-us/library/wdfskwcy.aspx public int ReceiveFrom ( byte buffer, ref EndPoint remoteEP )
0
7664
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7885
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
8106
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7638
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
6250
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
5213
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3642
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3626
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1198
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.