diff options
author | Bjoern A. Zeeb <bz@FreeBSD.org> | 2015-09-27 12:17:03 +0000 |
---|---|---|
committer | Bjoern A. Zeeb <bz@FreeBSD.org> | 2015-09-27 12:17:03 +0000 |
commit | 23d56b1e9c92d4ae149d62da8e306f1d422978df (patch) | |
tree | 4a5075a7b0ed9ebd75082f3c954b4d869d31d21f /sys | |
parent | 27aa47691e95be44e89282eff7964f1ac1f078d4 (diff) | |
download | src-23d56b1e9c92d4ae149d62da8e306f1d422978df.tar.gz src-23d56b1e9c92d4ae149d62da8e306f1d422978df.zip |
Compare the correct variable to see if memory allocation succeeded.
I don't even want to know where the symbol "version" comes from.
Spotted by: reading kernel compile time log
MFC after: 2 weeks
Notes
Notes:
svn path=/head/; revision=288307
Diffstat (limited to 'sys')
-rw-r--r-- | sys/dev/nxge/if_nxge.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/dev/nxge/if_nxge.c b/sys/dev/nxge/if_nxge.c index 90871aec9e88..af95e8bc2f87 100644 --- a/sys/dev/nxge/if_nxge.c +++ b/sys/dev/nxge/if_nxge.c @@ -1457,7 +1457,7 @@ xge_ioctl_stats(xge_lldev_t *lldev, struct ifreq *ifreqp) case XGE_READ_VERSION: info = xge_os_malloc(NULL, XGE_BUFFER_SIZE); - if(version != NULL) { + if(info != NULL) { strcpy(info, XGE_DRIVER_VERSION); if(copyout(info, ifreqp->ifr_data, XGE_BUFFER_SIZE) == 0) retValue = 0; |