Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 55634 - lpq (lpr-0.50.1-1) segfaults when trying to access a queue with entries in it.
lpq (lpr-0.50.1-1) segfaults when trying to access a queue with entries in it.
Product: Red Hat Linux
Classification: Retired
Component: lpr (Show other bugs)
i386 Linux
medium Severity high
: ---
: ---
Assigned To: Tim Waugh
Brock Organ
Depends On:
  Show dependency treegraph
Reported: 2001-11-03 07:28 EST by Michael McConnell
Modified: 2007-04-18 12:38 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-12-18 17:43:00 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Michael McConnell 2001-11-03 07:28:54 EST
From Bugzilla Helper:
User-Agent: Mozilla/4.78 [en] (X11; U; Linux 2.2.19 i586)

Description of problem:
lpq crashes with a segmentation fault when trying to query entries in a
printer queue when there are entries in it. 

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. Print something (e.g. RHS Printtool -> Tests -> Print Postscript test
page) with printer switched off. (This will make sure the queue can't
2. At a shell: lpq -Plpc


Actual Results:  Segmentation fault.
(no other information given)

Expected Results:  An entry detailing the entry in the queue, who sent it
and how big it is.

Additional info:

Occured both with the RHLinux compiled binary package, and a package
recompiled locally from the source RPM.

This is with lpr-0.50.1-1
Comment 1 Michael McConnell 2001-11-03 07:31:52 EST
My printer configuration:

Epson Stylus Color 880, connected via parallel port.
Using Epson Stylus Color (UP) driver on /dev/lp0,
with rhs-printfilters-1.63-4.rh6.2.i386.rpm installed.
Comment 2 Kuszmaul, Bradley 2001-11-05 01:16:26 EST
I get the same behavior (segfault) for a remote lpd printer.
Going back from package lpr-0.50.1-1 to lpr-0.50-7.6.x fixed the problem.
Comment 3 Fabrice Bellet 2001-11-06 04:53:45 EST
This line has been lost from previous lpr-0.50 version. This makes sense,
when cp here previously has a NULL value taken from the 
(cp = checkremote()) assignment fews lines above.

--- lpr-0.50.1/common_source/displayq.c.bak	Tue Nov  6 10:40:59 2001
+++ lpr-0.50.1/common_source/displayq.c	Tue Nov  6 10:41:15 2001
@@ -159,6 +159,7 @@
	else {
		/* get daemon pid */
		cp = current;
		ep = cp + sizeof(current) - 1;
		while ((c = getc(fp)) != EOF && c != '\n' && cp < ep)
Comment 4 Crutcher Dunnavant 2001-11-06 22:36:45 EST
Grumble. Will fix (again).
Comment 5 Tim Waugh 2002-01-10 06:54:01 EST
This is fixed now.

Note You need to log in before you can comment on or make changes to this bug.