usr.bin/make remove bad free()

看板DFBSD_submit作者時間21年前 (2004/11/12 18:01), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串1/2 (看更多)
This is a multi-part message in MIME format. --------------070801060500070605040702 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit The strings package passes back a pointer via brk_string() to internal memory, it should not be deallocated. The memory is allocated in str_init() and release in str_end() which are only called in main(). Max --------------070801060500070605040702 Content-Type: text/plain; name="patch-4.7" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="patch-4.7" --------------------- PatchSet 151 Date: 2000/08/18 11:41:37 Author: ru Log: Remove gratuitous free() call when we use special .SHELL target. Members: job.c:1.21->1.22 Index: job.c =================================================================== RCS file: /usr/home/okumoto/Work/make/fbsd-cvs/src/usr.bin/make/job.c,v retrieving revision 1.21 retrieving revision 1.22 diff -u -r1.21 -r1.22 --- job.c 16 Aug 2000 23:31:43 -0000 1.21 +++ job.c 18 Aug 2000 10:41:37 -0000 1.22 @@ -2762,11 +2762,6 @@ } } - /* - * Do not free up the words themselves, since they might be in use by the - * shell specification... - */ - free(words); return SUCCESS; } --------------070801060500070605040702--
文章代碼(AID): #11b8e600 (DFBSD_submit)
文章代碼(AID): #11b8e600 (DFBSD_submit)