diff options
| author | Jari Aalto <jari.aalto@cante.net> | 2005-12-07 14:08:12 +0000 |
|---|---|---|
| committer | Jari Aalto <jari.aalto@cante.net> | 2009-09-12 16:46:57 +0000 |
| commit | 95732b497d12c98613bb3c5db16b61f377501a59 (patch) | |
| tree | 5e1cdf79eb0407e09dca4c0ec29e11442c7d1d15 /dispose_cmd.c | |
| parent | eb87367179effbe5f430236db8259006d71438b7 (diff) | |
| download | android_external_bash-95732b497d12c98613bb3c5db16b61f377501a59.tar.gz android_external_bash-95732b497d12c98613bb3c5db16b61f377501a59.tar.bz2 android_external_bash-95732b497d12c98613bb3c5db16b61f377501a59.zip | |
Imported from ../bash-3.1.tar.gz.
Diffstat (limited to 'dispose_cmd.c')
| -rw-r--r-- | dispose_cmd.c | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/dispose_cmd.c b/dispose_cmd.c index 1a4c0d7..ee2e68c 100644 --- a/dispose_cmd.c +++ b/dispose_cmd.c @@ -1,6 +1,6 @@ /* dispose_command.c -- dispose of a COMMAND structure. */ -/* Copyright (C) 1987,1991 Free Software Foundation, Inc. +/* Copyright (C) 1987-2005 Free Software Foundation, Inc. This file is part of GNU Bash, the Bourne Again SHell. @@ -239,11 +239,16 @@ dispose_word (w) WORD_DESC *w; { FREE (w->word); -#if 0 - free (w); -#else ocache_free (wdcache, WORD_DESC, w); -#endif +} + +/* Free a WORD_DESC, but not the word contained within. */ +void +dispose_word_desc (w) + WORD_DESC *w; +{ + w->word = 0; + ocache_free (wdcache, WORD_DESC, w); } /* How to get rid of a linked list of words. A WORD_LIST. */ |
