Latest LQ Deal: Linux Power User Bundle
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


  Search this Thread
Old 11-01-2012, 01:06 AM   #1
LQ Newbie
Registered: Oct 2012
Distribution: ubuntu 11.10
Posts: 17

Rep: Reputation: Disabled
How to transfer hexadecimal data from client to server(socket programming)..?


Last edited by vktafs; 11-04-2012 at 11:35 PM.
Old 11-05-2012, 06:50 PM   #2
Senior Member
Registered: Jan 2009
Location: Austin, TX
Distribution: Mint-17.3 with Cinnamon & KDE
Posts: 1,601
Blog Entries: 3

Rep: Reputation: 105Reputation: 105
If you are running on the same workstation, you can fwrite( numeric ) ... fread( numeric ).
In all *nix, everything is a file -- that includes sockets. If your program works reading
and writing a disk file between them, it will work with a socket instead.

If you add a network between the client and server, TA-DA, same thing applies. Only now you
need to introduce parts for using a network socket instead of a local socket. Local sockets
are sometimes called "named pipes."

If the client and server are different architecture, you need to worry if numeric data
respects the same nature of "end-ian-ness." This means, is the first bit sent most significant
or least significant?

Good luck,
~~~ 0;-Dan


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
[SOLVED] TCP File Transfer in C with socket (server/client) on Linux. Help with code AscaL Programming 14 07-07-2015 02:46 PM
[SOLVED] How to connect a java client to a BSD server using socket programming sanju.lnt Programming 2 08-06-2011 03:57 PM
running socket programming (client/server) on single computer rahb20 Linux - Networking 5 09-17-2008 12:09 AM
cannot read data at server socket, though client socket sends it jacques83 Linux - Networking 0 11-15-2005 02:58 PM
how to implement fork() in socket programming b/w server/client in voice communicatio timeout4me Programming 1 08-05-2005 05:01 PM > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 08:03 AM.

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