Sponsored Content
Top Forums Programming Socket Programming file sending Post 302506846 by disaster on Tuesday 22nd of March 2011 06:05:35 AM
Old 03-22-2011
Which language do you use? In principle it is of course possible, e.g. using getchar to read from a file and then putchar to write to the socket (in C)
 

10 More Discussions You Might Find Interesting

1. Programming

Socket Programming socket

Hello, I actually try to make client-server program. I'm using SCO OpenServer Release 5.0.0 and when I try to compile my code (by TELNET) I've got this error : I'm just using this simple code : and I get the same error if I use : If someone can help me, Thanks (2 Replies)
Discussion started by: soshell
2 Replies

2. UNIX for Advanced & Expert Users

socket programming

Hi, I am trying to connect to more than 60 servers to perform some actions remotely. for this I am using ssh2. But its taking lot of time. Though i am running the command in background, still its taking long time to execute.. Any one let me know can we use sockets instead of ssh2 for... (3 Replies)
Discussion started by: pvamsikr
3 Replies

3. Programming

Socket programming in C

Hi, I wanted to write a socket program in C, where I always want my socket connected to the server. i.e i shouldn't get disconnected once i get the response back from the server. I want to work in the connected mode, instead of disconnect and connect. Can somebody please kindly provide me a... (3 Replies)
Discussion started by: sudharma
3 Replies

4. Programming

Socket Programming Send File

Hello my friends; Look at this 2 program: Client: #include <stdlib.h> #include <stdio.h> #include <string.h> #include <sys/socket.h> #include <sys/types.h> #include <netinet/in.h> #include <arpa/inet.h> int main ( int agrc, char *argv ) { int Socket; struct sockaddr_in... (5 Replies)
Discussion started by: htabesh
5 Replies

5. UNIX for Dummies Questions & Answers

Socket programming

in c socket programming, how can I send and received on the same port? (7 Replies)
Discussion started by: Peevish
7 Replies

6. UNIX for Dummies Questions & Answers

hi i need help with socket programming

in socket programming how can i : Create for example 3 blank files, namely: server, client, network •Server: act as servers/provider, will receive all requests from different client •Client: requesters •Network: middle-layer of communication between server & client any tips or... (6 Replies)
Discussion started by: kedah160
6 Replies

7. UNIX for Advanced & Expert Users

Socket programming

my socket program is not working with larger port numbers like more than 60000 , any reason why ? (4 Replies)
Discussion started by: Gopi Krishna P
4 Replies

8. Programming

help me about sending file through socket udp with c in linux

hi, i am newbie of socket. i want to ask some question. if i want to send file from client to server, how do i do? and if i want to send file from server to client, how do i do? any pro help me and if possible, you can post code for an example i need it very much thank you for helping me:)... (1 Reply)
Discussion started by: tung1984
1 Replies

9. Programming

sending http url through http socket programming..

hi am senthil am developing a software to send and receive SMS using HTTP connection first of all am forming a URL and sending that URL to a remote server using my Client Program i send that url through Socket(using Send() Function) if i send more than one URL one by one using the same... (0 Replies)
Discussion started by: senkerth
0 Replies

10. Shell Programming and Scripting

sending http url through http socket programming..

hi am senthil am developing a software to send and receive SMS using HTTP connection first of all am forming a URL and sending that URL to a remote server using my Client Program i send that url through Socket(using Send() Function) if i send more than one URL one by one using the same... (4 Replies)
Discussion started by: senkerth
4 Replies
PUTC(3) 						   BSD Library Functions Manual 						   PUTC(3)

NAME
fputc, putc, putc_unlocked, putchar, putchar_unlocked, putw -- output a character or word to a stream LIBRARY
Standard C Library (libc, -lc) SYNOPSIS
#include <stdio.h> int fputc(int c, FILE *stream); int putc(int c, FILE *stream); int putc_unlocked(int c, FILE *stream); int putchar(int c); int putchar_unlocked(int c); int putw(int w, FILE *stream); DESCRIPTION
The fputc() function writes the character c (converted to an ``unsigned char'') to the output stream pointed to by stream. The putc() macro acts essentially identically to fputc(), but is a macro that expands in-line. It may evaluate stream more than once, so arguments given to putc() should not be expressions with potential side effects. The putchar() function is identical to putc() with an output stream of stdout. The putw() function writes the specified int to the named output stream. The putc_unlocked() and putchar_unlocked() functions are equivalent to putc() and putchar() respectively, except that the caller is responsi- ble for locking the stream with flockfile(3) before calling them. These functions may be used to avoid the overhead of locking the stream for each character, and to avoid output being interspersed from multiple threads writing to the same stream. RETURN VALUES
The functions, fputc(), putc(), putchar(), putc_unlocked(), and putchar_unlocked() return the character written. If an error occurs, the value EOF is returned. The putw() function returns 0 on success; EOF is returned if a write error occurs, or if an attempt is made to write a read-only stream. SEE ALSO
ferror(3), flockfile(3), fopen(3), getc(3), putwc(3), stdio(3) STANDARDS
The functions fputc(), putc(), and putchar(), conform to ISO/IEC 9899:1990 (``ISO C90''). The putc_unlocked() and putchar_unlocked() func- tions conform to IEEE Std 1003.1-2001 (``POSIX.1''). A function putw() function appeared in Version 6 AT&T UNIX. BUGS
The size and byte order of an int varies from one machine to another, and putw() is not recommended for portable applications. BSD
January 10, 2003 BSD
All times are GMT -4. The time now is 02:08 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy