[Date Prev][Date Next]
back-perl coding error (ITS#1882)
Full_Name: Alexios Zavras
Submission from: (NULL) (126.96.36.199)
While building openldap-2.1.2, with --enable-perl,
I got a compilation error:
> modify.c: In function `perl_back_modify':
> modify.c:72: request for member `ad_cname' in something not a structure or
The line in question contains:
> XPUSHs(sv_2mortal(newSVpv( mods->sm_desc.ad_cname.bv_val, 0 )));
By looking at the definitions in servers/slapd/slap.h, it seems
that "mods", a "Modification *" has a member "sm_desc" which is
a "AttributeDescription *", not a "AttributeDescription".
My guess is that the correct way to write the line should be:
> XPUSHs(sv_2mortal(newSVpv( mods->sm_desc->ad_cname.bv_val, 0 )));
But I haven't actually looked further into it
(just what I can glimpse from C definitions).
On the other hand, how did it ever compile with such a blatant error ?