;void**
を取る関数の構造体ポインタをにキャストしようとしています。void**
typedef struct {
uint64_t key; // the key in the key/value pair
void *value; // the value in the key/value pair
} HTKeyValue, *HTKeyValuePtr;
HTKeyValuePtr payload = (HTKeyValuePtr)malloc(sizeof(HTKeyValue));
int success = (HTKeyValuePtr) LLIteratorGetPayload(i, (void**) &payload);
私に警告を与えます:
hashtable.c:161:19: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
hashtable.c:161:19: warning: initialization makes integer from pointer without a cast [enabled by default]
どうしたの?これを修正するにはどうすればよいですか?
これが他の質問の重複である場合は申し訳ありません。似たような質問がたくさんありましたが、自分の状況に合った質問が見つからず、理解できました。