Ticket #9 (closed defect: fixed)
Use of uninitialized value in string eq at /usr/bin/shelldap line 1470 for hasSubordinate attribute
| Reported by: | carnil | Owned by: | mahlon |
|---|---|---|---|
| Priority: | minor | Milestone: | |
| Version: | Keywords: | ||
| Cc: |
Description
Hi
In Debian there was reported that shelldap may trow out 'uninitalized value' warnings on comparison if hasSubordinate is TRUE [1].
(line 1470 is not true in original shelldap, and comes as shelldap in Debian has already the patch applied for ticket #8)
# if this entry is a container for other entries, append a
# trailing slash.
if ( $e->get_value('hasSubordinates') eq 'TRUE' ) {
$dn .= '/';
}
According to [2] the attibute can be either TRUE, or FALSE or the third case could be that the attribute is absent.
[2] http://www.openldap.org/lists/ietf-ldapbis/200210/msg00020.html
Should thus this first check if attribute is present, and then only compare the value?
Regards
Salvatore
Change History
comment:2 Changed 22 months ago by mahlon
- Status changed from new to accepted
- Owner set to mahlon
Hello, Salvatore!
I'm sitting on more than a couple patches that I need to get committed. I'll include a fix for this issue in the next milestone.
Thanks!
