projects
/
platform
/
upstream
/
bash.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Imported from ../bash-2.01.tar.gz.
[platform/upstream/bash.git]
/
dispose_cmd.c
diff --git
a/dispose_cmd.c
b/dispose_cmd.c
index
86443f1
..
d0b6bbd
100644
(file)
--- a/
dispose_cmd.c
+++ b/
dispose_cmd.c
@@
-175,18
+175,24
@@
dispose_words (list)
}
}
}
}
-/* How to dispose of an array of pointers to char. */
+#ifdef INCLUDE_UNUSED
+/* How to dispose of an array of pointers to char. This is identical to
+ free_array in stringlib.c. */
void
dispose_word_array (array)
char **array;
{
register int count;
void
dispose_word_array (array)
char **array;
{
register int count;
+ if (array == 0)
+ return;
+
for (count = 0; array[count]; count++)
free (array[count]);
free (array);
}
for (count = 0; array[count]; count++)
free (array[count]);
free (array);
}
+#endif
/* How to dispose of an list of redirections. A REDIRECT. */
void
/* How to dispose of an list of redirections. A REDIRECT. */
void