Bug 80669

Summary: bad source code
Product: [Retired] Red Hat Linux Reporter: d.binderman
Component: FreeWnnAssignee: Jens Petersen <petersen>
Status: CLOSED RAWHIDE QA Contact: Bill Huang <bhuang>
Severity: medium Docs Contact:
Priority: medium    
Version: 8.0   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2003-04-21 13:02:17 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description d.binderman 2002-12-29 17:15:04 UTC
From Bugzilla Helper:
User-Agent: Mozilla/4.6 [en-gb]C-CCK-MCD NetscapeOnline.co.uk  (Win98; I)

Description of problem:

Hello there,

I have just tried to compile package FreeWnn-1.11-27

I got the following messages from the compiler.

cc: Info: js.c, line 2887: In this statement, an array is being accessed outside the bounds specified for the array type. (subscrbounds)

Here is an untested patch to shut up the compiler.

./Xsi/Wnn/jlib/js.c.old ./Xsi/Wnn/jlib/js.c
*** ./Xsi/Wnn/jlib/js.c.old	Sat Dec 14 13:24:17 2002
--- ./Xsi/Wnn/jlib/js.c	Sat Dec 14 13:25:11 2002
*** 2871,2877 ****
       int cnt;
    FILE *fp;
!   static char s[6][EXPAND_PATH_LENGTH];
    char serv_defs[EXPAND_PATH_LENGTH];
    char data[1024];
    int num;
--- 2871,2877 ----
       int cnt;
    FILE *fp;
!   static char s[ 7][EXPAND_PATH_LENGTH];
    char serv_defs[EXPAND_PATH_LENGTH];
    char data[1024];
    int num;

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

How reproducible:

Steps to Reproduce:
1. copy source code onto Compaq Alpha machine.
2. compile with Compaq compiler, using flags -w0 -fast

Additional info:

Compaq compiler is not significant. Just think of it as a 
C compiler which has better warnings than the GNU compiler.

The FreeWnn source code fails to conform to the rules for ISO C.

Comment 1 Jens Petersen 2003-04-21 11:43:34 UTC
Ok, thanks for the patch.  Not sure whether this was
actually causing any problems, but I'll put the patch into
the next build.

Comment 2 Jens Petersen 2003-04-21 13:02:17 UTC
Patch added to 1.11-35.  Thanks :)

Comment 3 David Lawrence 2006-04-24 18:58:11 UTC
Adding to blocker bug 185486 and adding IBM group.

Comment 4 David Lawrence 2006-04-24 19:43:29 UTC
The last changes to these bugs were mistakenly made. Removing incorrect blocker
bug and confidential group.