diff options
author | Garrett D'Amore <garrett@damore.org> | 2022-07-10 15:46:47 -0400 |
---|---|---|
committer | Garrett D'Amore <garrett@damore.org> | 2022-07-14 16:33:31 -0400 |
commit | f81518d2d2ef63a80422631582fa82f0f956a850 (patch) | |
tree | 25cdad0f36dfdb9a97fcca929be7ec3daccb17a4 /usr | |
parent | a2d4222865d0ef80687403e52976bd691ec2faee (diff) | |
download | illumos-joyent-f81518d2d2ef63a80422631582fa82f0f956a850.tar.gz |
14797 scsi_cname is unsafe
Reviewed by: Toomas Soome <tsoome@me.com>
Reviewed by: Igor Kozhukhov <igor@dilos.org>
Approved by: Dan McDonald <danmcd@mnx.io>
Diffstat (limited to 'usr')
-rw-r--r-- | usr/src/uts/common/io/scsi/impl/scsi_subr.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/usr/src/uts/common/io/scsi/impl/scsi_subr.c b/usr/src/uts/common/io/scsi/impl/scsi_subr.c index 1fd97aeeb3..6542098fe2 100644 --- a/usr/src/uts/common/io/scsi/impl/scsi_subr.c +++ b/usr/src/uts/common/io/scsi/impl/scsi_subr.c @@ -21,6 +21,7 @@ /* * Copyright (c) 1990, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright 2022 Garrett D'Amore */ #include <sys/scsi/scsi.h> @@ -390,8 +391,6 @@ free_pktiopb(struct scsi_pkt *pkt, caddr_t datap, int datalen) * Common naming functions */ -static char scsi_tmpname[64]; - char * scsi_dname(int dtyp) { @@ -479,7 +478,7 @@ scsi_cname(uchar_t cmd, register char **cmdvec) } cmdvec++; } - return (sprintf(scsi_tmpname, "<undecoded cmd 0x%x>", cmd)); + return ("<undecoded cmd>"); } char * |