Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

storage_ldapvcard.c problem in shared roster group #16

Closed
mastervolkov opened this Issue · 2 comments

2 participants

@mastervolkov

in
storage/storage_ldapvcard.c

on 437^

            if (data->groupattr_regex != NULL && processregex(vals[0],data->groupattr_regex,2,1,group,sizeof(group),drv) !=0) {
                strncpy(group,vals[0],sizeof(group)-1);
            }
            group[sizeof(group)-1]='\0';
            ldap_value_free(vals);

in sm/mod_roster_publish.c on 573:

os_object_get_str(os, o, "group", &str)

ALWAYS returned ''(empty) if groupattr_regex in sm.xml not set (in my case - I use groupattr only )

@mastervolkov

These patch fix these issue

--- /tmp/DDDD/jabberd-2.2.17/jabberd-2.2.17/storage/storage_ldapvcard.c 2012-05-04 18:51:08.000000000 +0400
+++ RPM/BUILD/jabberd-2.2.17/storage/storage_ldapvcard.c 2012-11-30 10:43:11.348482828 +0400
@@ -430,7 +430,7 @@
ldap_value_free(vals);
continue;
}

  • if (data->groupattr_regex != NULL && processregex(vals[0],data->groupattr_regex,2,1,group,sizeof(group),drv) !=0) {
  • if ( (data->groupattr_regex != NULL && processregex(vals[0],data->groupattr_regex,2,1,group,sizeof(group),drv) !=0) || data->groupattr_regex == NULL) { strncpy(group,vals[0],sizeof(group)-1); } group[sizeof(group)-1]='\0';
@smokku smokku closed this in a7b2801
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.