test/nvme: extend name buffers to fit traddr

Fixes GCC 7 snprintf() overflow warnings.

Change-Id: Ie3a1b25f7dfab347a6ca24bcc5505f3eb4c832c5
Signed-off-by: Daniel Verkamp <daniel.verkamp@intel.com>
Reviewed-on: https://review.gerrithub.io/364303
Tested-by: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
This commit is contained in:
Daniel Verkamp 2017-06-06 11:18:30 -07:00
parent 9699e32d14
commit 66a0a5d4ff
3 changed files with 3 additions and 3 deletions

View File

@ -43,7 +43,7 @@ struct dev {
struct spdk_nvme_ctrlr *ctrlr; struct spdk_nvme_ctrlr *ctrlr;
struct spdk_nvme_health_information_page *health_page; struct spdk_nvme_health_information_page *health_page;
uint32_t orig_temp_threshold; uint32_t orig_temp_threshold;
char name[100]; char name[SPDK_NVMF_TRADDR_MAX_LEN + 1];
}; };
#define ADMINQ_SIZE 128 #define ADMINQ_SIZE 128

View File

@ -84,7 +84,7 @@ static uint16_t crc16_t10dif(uint8_t *buf, size_t len)
struct dev { struct dev {
struct spdk_nvme_ctrlr *ctrlr; struct spdk_nvme_ctrlr *ctrlr;
char name[100]; char name[SPDK_NVMF_TRADDR_MAX_LEN + 1];
}; };
static struct dev devs[MAX_DEVS]; static struct dev devs[MAX_DEVS];

View File

@ -47,7 +47,7 @@
struct dev { struct dev {
struct spdk_nvme_ctrlr *ctrlr; struct spdk_nvme_ctrlr *ctrlr;
char name[100]; char name[SPDK_NVMF_TRADDR_MAX_LEN + 1];
}; };
static struct dev devs[MAX_DEVS]; static struct dev devs[MAX_DEVS];