[freetds] RE: output parameters and "unknown marker"
ZIGLIO, Frediano, VF-IT
Frediano.Ziglio at vodafone.com
Fri Jan 7 08:20:01 EST 2005
>
> Josh, Freddy,
>
> The following change to src/dblib/rpc.c
> seems to fix the problem with NULL output parameters...
>
> in function param_info-alloc():
>
> tdsdump_log(TDS_DBG_INFO1, "parm_info_alloc(): parameter null-ness =
> %d\n", param_is_null);
>
> - if (param_is_null) {
> + if (param_is_null || (p->status & DBRPCRETURN)) {
>
> Would this be OK do you think freddy ?
> Josh, could you test it out ?
>
> Bill
>
If param is input/output and not null you pass also a null input
parameter, perhaps patch should be
- if (param_is_null) {
- temp_datalen = 0;
- temp_value = NULL;
+ if (param_is_null || (p->status & DBRPCRETURN)) {
+ if (param_is_null) {
+ temp_datalen = 0;
+ temp_value = NULL;
+ }
There should be a function that return nullable type from not-nullable.
freddy77
More information about the FreeTDS
mailing list