Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 06-25-2013, 12:55 PM   #1
LQ Newbie
Registered: Sep 2009
Posts: 6

Rep: Reputation: 0
Where is the true implementation of sendto

I am trying to explore the implementation of the "sendto" socket function. I tried to find an implementation in Linux.

In Linux, sendto function corresponds to "sys_sendto" system call. When I tried to follow it, I found a definition for it which is the following:

asmlinkage long sys_sendto (void) attribute((weak,alias("sys_ni_syscall"))

That's to say sys_sendto is nothing than an alias to sys_ni_syscall, which does nothing more than returning a value. That does not make sense, as far as I am concerned.

Besides, I found in another piece of code that "sys_sendto()" is calling "_sock_send_msg" which is in turn calling "_scok_sendmsg_nosec".

Where to find sys_snedto implementation? Is it implemented by some Assembly code? I want to find where exactly and how the information Ethernet Index is processed (passed to sendto fct in Raw socket context).
Old 07-06-2013, 06:53 PM   #2
Registered: Feb 2013
Location: Germany
Distribution: Jessie
Posts: 49

Rep: Reputation: 8



Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Sendto() error .... REmaxer Programming 2 10-16-2012 01:05 AM
about linux sendto mandeep.singh.bhatia Programming 2 09-14-2010 11:45 PM
[SOLVED] sendto doesn't send right away? homer_3 *BSD 1 08-07-2010 04:38 PM
Networking, sendto() dmiller Programming 1 04-01-2010 07:50 PM
sendto hangs digvijay.gahlot Linux - Networking 0 04-24-2009 08:22 AM

All times are GMT -5. The time now is 09:23 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration