07-28-04 11:19 PM
Hello Group,
(still undusting and porting an old framework for reliable
multicasting)
the following (original) code processes an error (error C2036: 'void
*' : unknown size)
int cntcp;
struct iovec *iov_set ;
// ... (determine size of cntcp)
iov_set->iov_base+=cntcp;
well, I understand very well that this will turn into an error, but
what do I do then? What was the original programmers goal? I guess he
tries (tried) to read the information received from the multicastgroup
and uses the cntcp variable to browse the iov_set->iov_base buffer.
The problem is that you cannot add an int to a void *, I think you
should add it to the address like this:
iov_set->iov_base = cntcp + &iov_set->iov_base;
this code doesnot give an error. Might my thinking be ok? Or does the
fact that iov_set is already a pointer on itself complicate things?
Thanks in advance,
--wim
[ Post a follow-up to this message ]
|