Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 10 Nov 2000 07:50:20 -0800
From:      Alfred Perlstein <bright@wintelcom.net>
To:        j mckitrick <jcm@FreeBSD-uk.eu.org>
Cc:        freebsd-questions@FreeBSD.ORG
Subject:   Re: programming a file transfer
Message-ID:  <20001110075020.D11449@fw.wintelcom.net>
In-Reply-To: <20001110152915.A18715@dogma.freebsd-uk.eu.org>; from jcm@FreeBSD-uk.eu.org on Fri, Nov 10, 2000 at 03:29:15PM %2B0000
References:  <20001110152915.A18715@dogma.freebsd-uk.eu.org>

next in thread | previous in thread | raw e-mail | index | archive | help
* j mckitrick <jcm@FreeBSD-uk.eu.org> [001110 07:29] wrote:
> 
> Hi all,
> 
> I am writing a very simple file server for a school project.  I have some
> sample code that got me started, and I have a server that opens a socket and
> waits for a request from a client.  The client reads from stdin and sends it
> to the server.
> 
> I want to have the server open a specified file and send it.  Can I just use
> fopen() and read data in chunks and send it that way?  Will it get mangled?
> Are there any issues I need to be aware of doing this?

You should be fine doing that.

-- 
-Alfred Perlstein - [bright@wintelcom.net|alfred@freebsd.org]
"I have the heart of a child; I keep it in a jar on my desk."


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20001110075020.D11449>