summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorimp <imp@FreeBSD.org>2006-04-27 20:47:13 +0000
committerimp <imp@FreeBSD.org>2006-04-27 20:47:13 +0000
commit4902e1489f8ca32b8e738bb36a7f8bec39589cd2 (patch)
tree57255c30844d25110993898956ba6251ed5d69e8 /sys
parent48b487a7191e90d2e85d3c853bead388f29eb967 (diff)
downloadFreeBSD-src-4902e1489f8ca32b8e738bb36a7f8bec39589cd2.zip
FreeBSD-src-4902e1489f8ca32b8e738bb36a7f8bec39589cd2.tar.gz
When pccard_safe_quote is passed NULL for src, it shouldn't panic.
Someone sent me this a while ago, but I can't find who to give them proper credit...
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/pccard/pccard.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/dev/pccard/pccard.c b/sys/dev/pccard/pccard.c
index aa01893..260909a 100644
--- a/sys/dev/pccard/pccard.c
+++ b/sys/dev/pccard/pccard.c
@@ -974,7 +974,7 @@ pccard_safe_quote(char *dst, const char *src, size_t len)
if (len == 0)
return;
- while (walker < ep)
+ while (src != NULL && walker < ep)
{
if (*src == '"') {
if (ep - walker < 2)
OpenPOWER on IntegriCloud