Can you try casting your string to a c char?
(*C.char)(unsafe.Pointer(string))
On Mon, Aug 6, 2018, 18:54 Amit Limaye wrote:
> the dll exported function signature takes a const char *
> while I am passing a string
> my golang call signature
>
> Open(lazyP*syscall.LazyProc, filter string, layer u
the dll exported function signature takes a const char *
while I am passing a string
my golang call signature
Open(lazyP*syscall.LazyProc, filter string, layer uint32, priority
int16, flags uint64) error
which I use to make this call
r1, r2, lastError :=
lazyP.Call(uintptr(unsafe.Pointer(syscall.
It doesn't look like you turn it to const anywhere, just a pointer. Is the
pointer conversion returning a const?
On Mon, Aug 6, 2018, 18:46 Amit Limaye wrote:
> is the const char * a problem my string is not passed as const ?
> -SIGTERM
> amit
>
> Humanity's first sin was faith, Its first virtu
is the const char * a problem my string is not passed as const ?
-SIGTERM
amit
Humanity's first sin was faith, Its first virtue doubt
On Mon, Aug 6, 2018 at 8:33 AM wrote:
>
> layer is an enum in the dll.
> Gets converted to uint32 inside the dll before it makes the windows api call.
> priority
layer is an enum in the dll.
Gets converted to uint32 inside the dll before it makes the windows api
call.
priority is exposed as int16 in the exported dll api
Regards
Amit
On Saturday, August 4, 2018 at 10:53:40 AM UTC-7, Oryan Moshe wrote:
>
> Seems to me like type issues as well, doesn't
Seems to me like type issues as well, doesn't seem like it for winapi to
receive int16.
On Sat, Aug 4, 2018, 07:18 wrote:
> I am trying to call a DLL from go and I get an error "The parameter is
> incorrect" error when I try to call this function
>
> HANDLE Myopen(const char *filter, LAYER laye
What is LAYER?
is priority an int16 or an uint16?
--
You received this message because you are subscribed to the Google Groups
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visi
I am trying to call a DLL from go and I get an error "The parameter is
incorrect" error when I try to call this function
HANDLE Myopen(const char *filter, LAYER layer, INT16 priority, UINT64
flags)
is my signature in the C file
I call from golang using this
Open(lazyP*syscall.LazyProc, fi