Subject Re: isc_service_attach strange issue
Author Dan Cooperstock
--- In firebird-support@yahoogroups.com, "adsarubbi" <adsarubbi@...>
wrote:
>
> Hi guys. I've wrote some functions in C to provide my Powerbuilder
> application access to low-level service manager utilities (user
> management, backup, restore, etc).
> One of my calls, to connect to the service manager is
isc_service_attach
> and there i got this behaviour
>
> the entrypoint of the function looks like:
>
> char * _stdcall _export user_modify(char * service_manager, ....)
>
> as isc_service_attach expects the service manager as a char *, i use
> directly the function argument service_manager.
>
> it works fine up to powerbuilder 9. but... in powerbuilder 10 it
> doesn't work. actually the error is: Could Not attach service
manager.
> service s could not be found
> "s" means that the isc_service_attach is receiving only the first
> character, no matter what i put in second parameter.
> But... if i return forcedly the parameter (return service_manager;)
i
> got the expected value, meaning the function actually gets the
parameter.
>
> i don't know who do i need to blame, because recently we updated to
> the 1.5.2 in our production fields, and got recently the
powerbuilder 10.
>
> Any help or any sugestion where to find help or where to start fight
> this problem will be appreciated.
>
>
> Compiler: Borland C++ 5.5
> C Language Target: DLL

Did you ever get this working? My guess is that it's a Unicode thing,
you need to make sure that PB knows the methods aren't Unicode (if
they aren't).

If you got it working, I'd love a copy!