Bug 21341 - gnuplot plots boxes with wrong widths
Summary: gnuplot plots boxes with wrong widths
Status: CLOSED RAWHIDE
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: gnuplot   
(Show other bugs)
Version: 7.0
Hardware: i386 Linux
medium
medium
Target Milestone: ---
Assignee: Bill Nottingham
QA Contact: Aaron Brown
URL:
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2000-11-26 03:37 UTC by Wagner T. Correa
Modified: 2014-03-17 02:17 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2001-06-03 07:17:59 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

Description Wagner T. Correa 2000-11-26 03:37:19 UTC
Given the following data in p1-5-hist.dat

22.5 5 5
27.5 13 5
32.5 17 5
37.5 8 5
60 12 40

And the gnuplot file:

set xrange [15:85]
set xtics 5
set data style boxes
plot "p1-5-hist.dat"

the gnuplot shipped with Red Hat Linux 7.0 produces the wrong graph:
http://www.cs.princeton.edu/~wtcorrea/gnuplot-wrong.jpg

The gnuplot available as a tarball from
ftp://ftp.dartmouth.edu/pub/gnuplot/gnuplot-3.7.tar.gz
produces the right graph:
http://www.cs.princeton.edu/~wtcorrea/gnuplot-right.jpg

Comment 1 Wagner T. Correa 2001-05-28 18:56:32 UTC
I found the bug.  There is a missing break statement in plot2d.c,  line 328.

*** plot2d.c	Mon May 28 14:51:30 2001
--- plot2d.c.orig	Mon May 28 14:51:20 2001
***************
*** 325,331 ****
      case BOXES:
  	min_cols = 2;
  	max_cols = 4;
! 	break;
      default:
  	min_cols = 1;
  	max_cols = 2;
--- 325,331 ----
      case BOXES:
  	min_cols = 2;
  	max_cols = 4;
! 
      default:
  	min_cols = 1;
  	max_cols = 2;


Comment 2 Wagner T. Correa 2001-06-03 05:32:53 UTC
The problem also happens with the gnuplot shipped with Red Hat Linux 7.1.

ps: I've changed the summary to better explain what the problem was, and I've
included Jakub in the cc list.

Comment 4 Bill Nottingham 2002-01-23 06:55:55 UTC
fixed in 3.7.1-15 - thanks!


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