From nobody@FreeBSD.org  Tue May  8 07:51:32 2001
Return-Path: <nobody@FreeBSD.org>
Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21])
	by hub.freebsd.org (Postfix) with ESMTP id E2E0F37B423
	for <freebsd-gnats-submit@FreeBSD.org>; Tue,  8 May 2001 07:51:31 -0700 (PDT)
	(envelope-from nobody@FreeBSD.org)
Received: (from nobody@localhost)
	by freefall.freebsd.org (8.11.1/8.11.1) id f48EpVP48405;
	Tue, 8 May 2001 07:51:31 -0700 (PDT)
	(envelope-from nobody)
Message-Id: <200105081451.f48EpVP48405@freefall.freebsd.org>
Date: Tue, 8 May 2001 07:51:31 -0700 (PDT)
From: conrad@th.physik.uni-bonn.de
To: freebsd-gnats-submit@FreeBSD.org
Subject: mail/cclient sucks rocks when saving over NFS mounts
X-Send-Pr-Version: www-1.0

>Number:         27203
>Category:       ports
>Synopsis:       mail/cclient sucks rocks when saving over NFS mounts
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    dwcjr
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue May 08 08:00:11 PDT 2001
>Closed-Date:    Mon Jun 18 09:20:47 PDT 2001
>Last-Modified:  Mon Jun 18 09:21:21 PDT 2001
>Originator:     Jan Conrad
>Release:        FreeBSD4.3R
>Organization:
Univ. Bonn, Germany
>Environment:
does'nt matter
>Description:
pine writes out mailboxes in 512 byte chunks (using cclient)
>How-To-Repeat:
On an NFS mounted home go to a 2MB message and type (S)ave
Then walk over to your file server and listen how your disks go wild!

>Fix:
This is the fix for cclient (I'll send another PR for pine)

Of course one could do that in a nicer way, but I already spent a lot
of time to find that out...

diff -ruN src/osdep/unix/unix.c.orig src/osdep/unix/unix.c
--- src/osdep/unix/unix.c.orig  Thu Apr 12 04:15:44 2001
+++ src/osdep/unix/unix.c       Tue May  8 16:48:07 2001
@@ -914,6 +914,7 @@
   }
   fstat (fd,&sbuf);            /* get current file size */
   rewind (sf);
+  setvbuf (df, NULL, _IOFBF, 32*1024);
   for (; i && ((j = fread (buf,1,min ((long) BUFLEN,i),sf)) &&
               (fwrite (buf,1,j,df) == j)); i -= j);
   fclose (sf);                 /* done with scratch file */

>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports->dwcjr 
Responsible-Changed-By: dwcjr 
Responsible-Changed-When: Sat Jun 16 23:30:38 PDT 2001 
Responsible-Changed-Why:  
I'll hanlde this one 

http://www.FreeBSD.org/cgi/query-pr.cgi?pr=27203 

From: "David W. Chapman Jr." <dwcjr@inethouston.net>
To: freebsd-gnats-submit@FreeBSD.org, conrad@th.physik.uni-bonn.de
Cc:  
Subject: Re: ports/27203: mail/cclient sucks rocks when saving over NFS mounts
Date: Sun, 17 Jun 2001 01:30:36 -0500

 Has this been sent to the authors?  What does the maintainer think?
 
State-Changed-From-To: open->closed 
State-Changed-By: dwcjr 
State-Changed-When: Mon Jun 18 09:20:47 PDT 2001 
State-Changed-Why:  
Timeout without getting maintainer's approval. 

http://www.FreeBSD.org/cgi/query-pr.cgi?pr=27203 
>Unformatted:
