From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stas Sergeev Subject: Re: Printing stops after 6 pages Date: Mon, 15 Mar 2004 21:11:09 +0300 Sender: linux-msdos-owner@vger.kernel.org Message-ID: <4055F1BD.5020908@aknet.ru> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------090909080103070202050705" Return-path: List-Id: To: linux-msdos@vger.kernel.org --------------090909080103070202050705 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Hello. Denny Schierz wrote: > we using dosemu 1.3.0 with direct printing. The problem is, if we > printing more than six pages, the printer stops. I can't find any > solution for that :-/ > any hinds? Try -D9+p log, maybe that will shed some light on a problem. But even at a first glance there seem to be a memory leak in a printer code, which is probably responsible for your problem. Try the attached patch. --------------090909080103070202050705 Content-Type: text/plain; name="lpt.diff" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="lpt.diff" --- src/base/dev/misc/lpt.c Sun Jan 18 00:30:29 2004 +++ src/base/dev/misc/lpt.c Mon Mar 15 21:04:07 2004 @@ -155,6 +155,7 @@ if (pipe == NULL) error("system(\"%s\") in lpt.c failed, cannot print!\ Command returned error %s\n", cmdbuf, strerror(errno)); + free(cmdbuf); bufsize = ftell(lpt[prnum].file); buf = malloc(bufsize); --------------090909080103070202050705 Content-Type: text/plain Scanned by evaluation version of Dr.Web antivirus Daemon http://drweb.ru/unix/ --------------090909080103070202050705--