~ttx/openldap/lucid-gssapi-495418

« back to all changes in this revision

Viewing changes to libraries/libldap/add.c

  • Committer: Bazaar Package Importer
  • Author(s): Steve Langasek, Updated debconf translations
  • Date: 2009-07-28 10:17:15 UTC
  • mfrom: (1.1.4 upstream) (0.2.2 sid)
  • mto: (0.2.4 sid)
  • mto: This revision was merged to the branch mainline in revision 16.
  • Revision ID: james.westby@ubuntu.com-20090728101715-epwmqmsk0d3h22k3
* New upstream version.
  - Fixes FTBFS on ia64 with -fPIE. Closes: #524770.
  - Fixes some TLS issues with GnuTLS.  Closes: #505191.
* Update priority of libldap-2.4-2 to match the archive override.
* Add the missing ldapexop and ldapurl tools to ldap-utils, as well as the
  ldapurl(1) manpage.  Thanks to Peter Marschall for the patch.
  Closes: #496749.
* Bump build-dependency on debhelper to 6 instead of 5, since that's
  what we're using.  Closes: #498116.
* Set the default SLAPD_SERVICES to ldap:/// ldapi:///, instead of using
  the built-in default of ldap:/// only.
* Build-depend on libltdl-dev | libltdl3-dev (>= 1.4.3), for the package
  name change.  Closes: #522965.

[ Updated debconf translations ]
* Spanish, thanks to Francisco Javier Cuadrado <fcocuadrado@gmail.com>.
  Closes: #521804.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/* add.c */
2
 
/* $OpenLDAP: pkg/ldap/libraries/libldap/add.c,v 1.27.2.3 2008/02/11 23:26:41 kurt Exp $ */
 
2
/* $OpenLDAP: pkg/ldap/libraries/libldap/add.c,v 1.27.2.5 2009/01/22 00:00:54 kurt Exp $ */
3
3
/* This work is part of OpenLDAP Software <http://www.openldap.org/>.
4
4
 *
5
 
 * Copyright 1998-2008 The OpenLDAP Foundation.
 
5
 * Copyright 1998-2009 The OpenLDAP Foundation.
6
6
 * All rights reserved.
7
7
 *
8
8
 * Redistribution and use in source and binary forms, with or without
151
151
                /* for each attribute in the entry... */
152
152
                for ( i = 0; attrs[i] != NULL; i++ ) {
153
153
                        if ( ( attrs[i]->mod_op & LDAP_MOD_BVALUES) != 0 ) {
 
154
                                int j;
 
155
 
 
156
                                if ( attrs[i]->mod_bvalues == NULL ) {
 
157
                                        ld->ld_errno = LDAP_PARAM_ERROR;
 
158
                                        ber_free( ber, 1 );
 
159
                                        return ld->ld_errno;
 
160
                                }
 
161
 
 
162
                                for ( j = 0; attrs[i]->mod_bvalues[ j ] != NULL; j++ ) {
 
163
                                        if ( attrs[i]->mod_bvalues[ j ]->bv_val == NULL ) {
 
164
                                                ld->ld_errno = LDAP_PARAM_ERROR;
 
165
                                                ber_free( ber, 1 );
 
166
                                                return ld->ld_errno;
 
167
                                        }
 
168
                                }
 
169
 
154
170
                                rc = ber_printf( ber, "{s[V]N}", attrs[i]->mod_type,
155
171
                                    attrs[i]->mod_bvalues );
 
172
 
156
173
                        } else {
 
174
                                if ( attrs[i]->mod_values == NULL ) {
 
175
                                        ld->ld_errno = LDAP_PARAM_ERROR;
 
176
                                        ber_free( ber, 1 );
 
177
                                        return ld->ld_errno;
 
178
                                }
 
179
 
157
180
                                rc = ber_printf( ber, "{s[v]N}", attrs[i]->mod_type,
158
181
                                    attrs[i]->mod_values );
159
182
                        }