fix some compiler warnings
This commit is contained in:
@@ -25,7 +25,7 @@ int T0102_read10_0blocks(const char *initiator, const char *url)
|
||||
struct iscsi_context *iscsi;
|
||||
struct scsi_task *task;
|
||||
struct scsi_readcapacity10 *rc10;
|
||||
int ret, i, lun;
|
||||
int ret, lun;
|
||||
uint32_t block_size, num_blocks;
|
||||
|
||||
iscsi = iscsi_context_login(initiator, url, &lun);
|
||||
|
||||
@@ -229,7 +229,7 @@ test5:
|
||||
task->expxferlen = sizeof(buf);
|
||||
|
||||
data.size = sizeof(buf);
|
||||
data.data = &buf[0];
|
||||
data.data = (unsigned char *)&buf[0];
|
||||
|
||||
if (iscsi_scsi_command_sync(iscsi, lun, task, &data) == NULL) {
|
||||
printf("[FAILED]\n");
|
||||
|
||||
@@ -25,7 +25,7 @@ int T0110_readcapacity10_simple(const char *initiator, const char *url)
|
||||
struct iscsi_context *iscsi;
|
||||
struct scsi_task *task;
|
||||
struct scsi_readcapacity10 *rc10;
|
||||
int ret, i, lun;
|
||||
int ret, lun;
|
||||
|
||||
ret = 0;
|
||||
|
||||
|
||||
@@ -229,7 +229,7 @@ test5:
|
||||
task->expxferlen = sizeof(buf);
|
||||
|
||||
data.size = sizeof(buf);
|
||||
data.data = &buf[0];
|
||||
data.data = (unsigned char *)&buf[0];
|
||||
|
||||
if (iscsi_scsi_command_sync(iscsi, lun, task, &data) == NULL) {
|
||||
printf("[FAILED]\n");
|
||||
|
||||
@@ -66,7 +66,7 @@ int T0130_verify10_simple(const char *initiator, const char *url)
|
||||
/* read and verify the first 1 - 256 blocks at the start of the LUN */
|
||||
printf("Read+verify first 1-256 blocks ... ");
|
||||
for (i = 1; i <= 256; i++) {
|
||||
char *buf;
|
||||
unsigned char *buf;
|
||||
|
||||
task = iscsi_read10_sync(iscsi, lun, 0, i * block_size, block_size);
|
||||
if (task == NULL) {
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include "iscsi.h"
|
||||
#include "scsi-lowlevel.h"
|
||||
#include "iscsi-test.h"
|
||||
@@ -66,7 +67,7 @@ int T0131_verify10_mismatch(const char *initiator, const char *url)
|
||||
/* read and verify the first 1 - 256 blocks at the start of the LUN */
|
||||
printf("Read+verify first 1-256 blocks ... ");
|
||||
for (i = 1; i <= 256; i++) {
|
||||
char *buf;
|
||||
unsigned char *buf;
|
||||
|
||||
task = iscsi_read10_sync(iscsi, lun, 0, i * block_size, block_size);
|
||||
if (task == NULL) {
|
||||
|
||||
Reference in New Issue
Block a user