Re: invalid conversion from void* to void**
Re: invalid conversion from void* to void**
- Subject: Re: invalid conversion from void* to void**
- From: "Marc Wan" <email@hidden>
- Date: Sat, 7 Oct 2006 14:51:22 +0800
ni hao!
QueryInterface requires the last parameter to be
of type (void **). You've cast your pointer to a pointer as LPVOID,
which is (void *). I'd just change the cast to either (void **) or
(LPVOID *).
[As an aside, where does one use QueryInterface on a Mac ???]
marc.
On 10/7/06, Alfred Van Hoek <
email@hidden> wrote:Might be trivial, but what used to compile does not anymore:
Given:
IOFireWireAVCLibUnitInterface** avcUnit;
// ask for the AVC unit interface
result = (*interface)->QueryInterface( interface,
CFUUIDGetUUIDBytes( kIOFireWireAVCLibUnitInterfaceID ),
(LPVOID)&avcUnit );
The compiler chokes on (LPVOID)&avcUnit. This is how it should be called though, (LPVoid)avcUnit will lead to a crash. Any pointers?
Allfred
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden