bug-gnats
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

A bug in file-pr


From: Robert Lupton the Good
Subject: A bug in file-pr
Date: Tue, 13 Mar 2001 10:46:53 -0500 (EST)

There's a bug in v3.112 file-pr where a string length check is wrong
in append_notify(); here's the patch.

This has been a particularily annoying one, as it results in the
gnatsd.lock file being left behind.


                                R


as:gnats>cvs diff file-pr.c 
Index: file-pr.c
===================================================================
RCS file: /cvs/gnats/gnats/gnats/file-pr.c,v
retrieving revision 1.3.2.1.2.1.2.3
diff -a -c -r1.3.2.1.2.1.2.3 file-pr.c
*** file-pr.c   1999/10/31 06:57:45     1.3.2.1.2.1.2.3
--- file-pr.c   2001/03/13 15:39:29
***************
*** 678,684 ****
         n = (responsible != NULL && responsible->key != NULL)
         ? responsible->alias : p;
  
!        i = strlen (p);
         /* add in +2 to make checking the second case not a hassle. */
         if ((i + notify_len + 2) >= notify_size)
         {
--- 678,684 ----
         n = (responsible != NULL && responsible->key != NULL)
         ? responsible->alias : p;
  
!        i = strlen (n);
         /* add in +2 to make checking the second case not a hassle. */
         if ((i + notify_len + 2) >= notify_size)
         {



reply via email to

[Prev in Thread] Current Thread [Next in Thread]