Date: Fri, 14 Nov 1997 11:12:08 -0800 (PST) From: rich@math.missouri.edu To: freebsd-gnats-submit@FreeBSD.ORG Subject: i386/5044: Linux emul: Missing offset assignment in linux_truncate function Message-ID: <199711141912.LAA24144@hub.freebsd.org> Resent-Message-ID: <199711141920.LAA24742@hub.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 5044 >Category: i386 >Synopsis: Linux emul: Missing offset assignment in linux_truncate function >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-bugs >State: open >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Fri Nov 14 11:20:01 PST 1997 >Last-Modified: >Originator: Richard Winkel >Organization: Univ of Missouri >Release: 2.2.5 >Environment: FreeBSD lisa.math.missouri.edu 2.2.5-STABLE FreeBSD 2.2.5-STABLE #0: Thu Nov 6 13:47:01 CST 1997 root@:/usr/src/sys/compile/g6_200_1 i386 >Description: Linux function "linux_truncate" forgets to assign callers offset argument to bsd "otruncate" argument. Results in a random offset, which adds MB's of nulls to the end of the affected file. >How-To-Repeat: Problem is triggered by linux port of mathematica. All file saves results in huge files which consist of the actual data followed by MB's of nulls. >Fix: At bottom of /usr/src/sys/i386/linux/linux_file.c, insert one line: bsd.path = args->path; bsd.length = args->length; /* this is the fix */ return otruncate(p, &bsd, retval); >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199711141912.LAA24144>