cpplex.c (_cpp_get_buff): Fix off-by-one error that caused memory leak.
* cpplex.c (_cpp_get_buff): Fix off-by-one error that caused memory leak. From-SVN: r46317
This commit is contained in:
parent
645ca34390
commit
34f5271ddd
|
@ -1,3 +1,8 @@
|
|||
2001-10-17 Richard Earnshaw <rearnsha@arm.com>
|
||||
|
||||
* cpplex.c (_cpp_get_buff): Fix off-by-one error that caused memory
|
||||
leak.
|
||||
|
||||
Wed Oct 17 05:26:39 2001 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
|
||||
|
||||
* Makefile.in (print-rtl.o): Depend on TREE_H.
|
||||
|
|
|
@ -2116,7 +2116,7 @@ _cpp_get_buff (pfile, min_size)
|
|||
size = result->limit - result->base;
|
||||
/* Return a buffer that's big enough, but don't waste one that's
|
||||
way too big. */
|
||||
if (size >= min_size && size < BUFF_SIZE_UPPER_BOUND (min_size))
|
||||
if (size >= min_size && size <= BUFF_SIZE_UPPER_BOUND (min_size))
|
||||
break;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue