Diff for /servers/slapd/overlays/auditlog.c between versions 1.5 and 1.6

version 1.5, 2006/04/02 14:40:39 version 1.6, 2006/04/02 17:54:26
Line 1 Line 1
 /* auditlog.c - log modifications for audit/history purposes */  /* auditlog.c - log modifications for audit/history purposes */
 /* $OpenLDAP: pkg/ldap/servers/slapd/overlays/auditlog.c,v 1.4 2006/02/09 23:31:17 hyc Exp $ */  /* $OpenLDAP: pkg/ldap/servers/slapd/overlays/auditlog.c,v 1.5 2006/04/02 14:40:39 hallvard Exp $ */
 /* This work is part of OpenLDAP Software <http://www.openldap.org/>.  /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
  *   *
  * Copyright 2005-2006 The OpenLDAP Foundation.   * Copyright 2005-2006 The OpenLDAP Foundation.
Line 52  static int auditlog_response(Operation * Line 52  static int auditlog_response(Operation *
         Attribute *a;          Attribute *a;
         Modifications *m;          Modifications *m;
         struct berval *b;          struct berval *b;
         char *what, *subop, *suffix, *who = NULL;          char *what, *suffix, *who = NULL;
         long stamp = slap_get_time();          long stamp = slap_get_time();
         int i;          int i;
   
Line 111  static int auditlog_response(Operation * Line 111  static int auditlog_response(Operation *
         switch(op->o_tag) {          switch(op->o_tag) {
           case LDAP_REQ_ADD:            case LDAP_REQ_ADD:
                 for(a = op->ora_e->e_attrs; a; a = a->a_next)                  for(a = op->ora_e->e_attrs; a; a = a->a_next)
                     if(b = a->a_vals)                    if((b = a->a_vals) != NULL)
                         for(i = 0; b[i].bv_val; i++)                          for(i = 0; b[i].bv_val; i++)
                                 fprint_ldif(f, a->a_desc->ad_cname.bv_val, b[i].bv_val, b[i].bv_len);                                  fprint_ldif(f, a->a_desc->ad_cname.bv_val, b[i].bv_val, b[i].bv_len);
                 break;                  break;
Line 128  static int auditlog_response(Operation * Line 128  static int auditlog_response(Operation *
                                         continue;                                          continue;
                         }                          }
                         fprintf(f, "%s: %s\n", what, m->sml_desc->ad_cname.bv_val);                          fprintf(f, "%s: %s\n", what, m->sml_desc->ad_cname.bv_val);
                         if(b = m->sml_values) for(i = 0; b[i].bv_val; i++)                          if((b = m->sml_values) != NULL)
                             for(i = 0; b[i].bv_val; i++)
                                 fprint_ldif(f, m->sml_desc->ad_cname.bv_val, b[i].bv_val, b[i].bv_len);                                  fprint_ldif(f, m->sml_desc->ad_cname.bv_val, b[i].bv_val, b[i].bv_len);
                         fprintf(f, "-\n");                          fprintf(f, "-\n");
                 }                  }

Removed from v.1.5  
changed lines
  Added in v.1.6


______________
© Copyright 1998-2020, OpenLDAP Foundation, info@OpenLDAP.org