diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-03 05:34:56 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-03 05:34:56 +0000 |
commit | 3102bdaf142acf3c952310cb620274258492a795 (patch) | |
tree | 907e389a831fe1f9dc5d94479d8457584b352434 /clients/tools | |
parent | Adding debian version 2.6.7+dfsg-1~exp1. (diff) | |
download | openldap-3102bdaf142acf3c952310cb620274258492a795.tar.xz openldap-3102bdaf142acf3c952310cb620274258492a795.zip |
Merging upstream version 2.6.8+dfsg.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'clients/tools')
-rw-r--r-- | clients/tools/Makefile.in | 2 | ||||
-rw-r--r-- | clients/tools/common.c | 4 | ||||
-rw-r--r-- | clients/tools/common.h | 2 | ||||
-rw-r--r-- | clients/tools/ldapcompare.c | 2 | ||||
-rw-r--r-- | clients/tools/ldapdelete.c | 2 | ||||
-rw-r--r-- | clients/tools/ldapexop.c | 2 | ||||
-rw-r--r-- | clients/tools/ldapmodify.c | 26 | ||||
-rw-r--r-- | clients/tools/ldapmodrdn.c | 2 | ||||
-rw-r--r-- | clients/tools/ldappasswd.c | 2 | ||||
-rw-r--r-- | clients/tools/ldapsearch.c | 2 | ||||
-rw-r--r-- | clients/tools/ldapurl.c | 2 | ||||
-rw-r--r-- | clients/tools/ldapvc.c | 2 | ||||
-rw-r--r-- | clients/tools/ldapwhoami.c | 2 |
13 files changed, 35 insertions, 17 deletions
diff --git a/clients/tools/Makefile.in b/clients/tools/Makefile.in index 1fecb61..f266dd4 100644 --- a/clients/tools/Makefile.in +++ b/clients/tools/Makefile.in @@ -2,7 +2,7 @@ # $OpenLDAP$ ## This work is part of OpenLDAP Software <http://www.openldap.org/>. ## -## Copyright 1998-2022 The OpenLDAP Foundation. +## Copyright 1998-2024 The OpenLDAP Foundation. ## All rights reserved. ## ## Redistribution and use in source and binary forms, with or without diff --git a/clients/tools/common.c b/clients/tools/common.c index 9dfbb53..1c6513e 100644 --- a/clients/tools/common.c +++ b/clients/tools/common.c @@ -2,7 +2,7 @@ /* $OpenLDAP$ */ /* This work is part of OpenLDAP Software <http://www.openldap.org/>. * - * Copyright 1998-2022 The OpenLDAP Foundation. + * Copyright 1998-2024 The OpenLDAP Foundation. * Portions Copyright 2003 Kurt D. Zeilenga. * Portions Copyright 2003 IBM Corporation. * All rights reserved. @@ -2211,7 +2211,7 @@ print_vlv( LDAP *ld, LDAPControl *ctrl ) ber_memfree( bv.bv_val ); tool_write_ldif( ldif ? LDIF_PUT_COMMENT : LDIF_PUT_VALUE, - ldif ? "vlvResult" : "vlvResult", buf, rc ); + ldif ? "vlvResult: " : "vlvResult", buf, rc ); } return rc; diff --git a/clients/tools/common.h b/clients/tools/common.h index c4377da..2eb2cef 100644 --- a/clients/tools/common.h +++ b/clients/tools/common.h @@ -2,7 +2,7 @@ /* $OpenLDAP$ */ /* This work is part of OpenLDAP Software <http://www.openldap.org/>. * - * Copyright 1998-2022 The OpenLDAP Foundation. + * Copyright 1998-2024 The OpenLDAP Foundation. * All rights reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/clients/tools/ldapcompare.c b/clients/tools/ldapcompare.c index 63c3040..e571600 100644 --- a/clients/tools/ldapcompare.c +++ b/clients/tools/ldapcompare.c @@ -2,7 +2,7 @@ /* $OpenLDAP$ */ /* This work is part of OpenLDAP Software <http://www.openldap.org/>. * - * Copyright 1998-2022 The OpenLDAP Foundation. + * Copyright 1998-2024 The OpenLDAP Foundation. * Portions Copyright 1998-2003 Kurt D. Zeilenga. * Portions Copyright 1998-2001 Net Boolean Incorporated. * All rights reserved. diff --git a/clients/tools/ldapdelete.c b/clients/tools/ldapdelete.c index a66900d..f31e5bb 100644 --- a/clients/tools/ldapdelete.c +++ b/clients/tools/ldapdelete.c @@ -2,7 +2,7 @@ /* $OpenLDAP$ */ /* This work is part of OpenLDAP Software <http://www.openldap.org/>. * - * Copyright 1998-2022 The OpenLDAP Foundation. + * Copyright 1998-2024 The OpenLDAP Foundation. * Portions Copyright 1998-2003 Kurt D. Zeilenga. * All rights reserved. * diff --git a/clients/tools/ldapexop.c b/clients/tools/ldapexop.c index bfe6e4e..d66f2cf 100644 --- a/clients/tools/ldapexop.c +++ b/clients/tools/ldapexop.c @@ -2,7 +2,7 @@ /* $OpenLDAP$ */ /* This work is part of OpenLDAP Software <http://www.openldap.org/>. * - * Copyright 2005-2022 The OpenLDAP Foundation. + * Copyright 2005-2024 The OpenLDAP Foundation. * All rights reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/clients/tools/ldapmodify.c b/clients/tools/ldapmodify.c index 33b723b..032e4e1 100644 --- a/clients/tools/ldapmodify.c +++ b/clients/tools/ldapmodify.c @@ -2,7 +2,7 @@ /* $OpenLDAP$ */ /* This work is part of OpenLDAP Software <http://www.openldap.org/>. * - * Copyright 1998-2022 The OpenLDAP Foundation. + * Copyright 1998-2024 The OpenLDAP Foundation. * Portions Copyright 2006 Howard Chu. * Portions Copyright 1998-2003 Kurt D. Zeilenga. * Portions Copyright 1998-2001 Net Boolean Incorporated. @@ -97,6 +97,7 @@ static int process_response( static int txn = 0; static int txnabort = 0; struct berval *txn_id = NULL; +static unsigned long jumpline; void usage( void ) @@ -113,6 +114,7 @@ usage( void ) fprintf( stderr, _(" -E [!]ext=extparam modify extensions" " (! indicate s criticality)\n")); fprintf( stderr, _(" -f file read operations from `file'\n")); + fprintf( stderr, _(" -j lineno jump to lineno before processing\n")); fprintf( stderr, _(" -M enable Manage DSA IT control (-MM to make critical)\n")); fprintf( stderr, _(" -P version protocol version (default: 3)\n")); fprintf( stderr, @@ -125,7 +127,7 @@ usage( void ) const char options[] = "aE:rS:" - "cd:D:e:f:H:IMnNO:o:P:QR:U:vVw:WxX:y:Y:Z"; + "cd:D:e:f:H:Ij:MnNO:o:P:QR:U:vVw:WxX:y:Y:Z"; int handle_private_option( int i ) @@ -187,6 +189,17 @@ handle_private_option( int i ) ldapadd = 1; break; + case 'j': /* jump */ + { + char *next; + jumpline = strtoul( optarg, &next, 10 ); + if ( !next || *next ) { + fprintf( stderr, "%s: unable to parse jump line number \"%s\"\n", prog, optarg); + exit(EXIT_FAILURE); + } + } + break; + case 'r': /* replace (obsolete) */ break; @@ -286,6 +299,9 @@ main( int argc, char **argv ) while (( rc == 0 || contoper ) && ( ldifrc = ldif_read_record( ldiffp, &nextline, &rbuf, &lmax )) > 0 ) { + if ( lineno < jumpline ) + goto next; + if ( rejfp ) { len = strlen( rbuf ); if (( rejbuf = (char *)ber_memalloc( len+1 )) == NULL ) { @@ -297,11 +313,10 @@ main( int argc, char **argv ) } rc = process_ldif_rec( rbuf, lineno ); - lineno = nextline+1; if ( rc ) retval = rc; if ( rc && rejfp ) { - fprintf(rejfp, _("# Error: %s (%d)"), ldap_err2string(rc), rc); + fprintf(rejfp, _("# Error: %s (%d) (line=%lu)"), ldap_err2string(rc), rc, lineno); matched_msg = NULL; ldap_get_option(ld, LDAP_OPT_MATCHED_DN, &matched_msg); @@ -324,6 +339,9 @@ main( int argc, char **argv ) } if (rejfp) ber_memfree( rejbuf ); + +next: + lineno = nextline+1; } ber_memfree( rbuf ); diff --git a/clients/tools/ldapmodrdn.c b/clients/tools/ldapmodrdn.c index 40a482f..1197d38 100644 --- a/clients/tools/ldapmodrdn.c +++ b/clients/tools/ldapmodrdn.c @@ -2,7 +2,7 @@ /* $OpenLDAP$ */ /* This work is part of OpenLDAP Software <http://www.openldap.org/>. * - * Copyright 1998-2022 The OpenLDAP Foundation. + * Copyright 1998-2024 The OpenLDAP Foundation. * Portions Copyright 1998-2003 Kurt D. Zeilenga. * Portions Copyright 1998-2001 Net Boolean Incorporated. * Portions Copyright 2001-2003 IBM Corporation. diff --git a/clients/tools/ldappasswd.c b/clients/tools/ldappasswd.c index 0d1ce84..cd0650e 100644 --- a/clients/tools/ldappasswd.c +++ b/clients/tools/ldappasswd.c @@ -2,7 +2,7 @@ /* $OpenLDAP$ */ /* This work is part of OpenLDAP Software <http://www.openldap.org/>. * - * Copyright 1998-2022 The OpenLDAP Foundation. + * Copyright 1998-2024 The OpenLDAP Foundation. * Portions Copyright 1998-2003 Kurt D. Zeilenga. * Portions Copyright 1998-2001 Net Boolean Incorporated. * Portions Copyright 2001-2003 IBM Corporation. diff --git a/clients/tools/ldapsearch.c b/clients/tools/ldapsearch.c index 69e172c..41595e2 100644 --- a/clients/tools/ldapsearch.c +++ b/clients/tools/ldapsearch.c @@ -2,7 +2,7 @@ /* $OpenLDAP$ */ /* This work is part of OpenLDAP Software <http://www.openldap.org/>. * - * Copyright 1998-2022 The OpenLDAP Foundation. + * Copyright 1998-2024 The OpenLDAP Foundation. * Portions Copyright 1998-2003 Kurt D. Zeilenga. * Portions Copyright 1998-2001 Net Boolean Incorporated. * Portions Copyright 2001-2003 IBM Corporation. diff --git a/clients/tools/ldapurl.c b/clients/tools/ldapurl.c index efc4896..26f08b3 100644 --- a/clients/tools/ldapurl.c +++ b/clients/tools/ldapurl.c @@ -2,7 +2,7 @@ /* $OpenLDAP$ */ /* This work is part of OpenLDAP Software <http://www.openldap.org/>. * - * Copyright 2008-2022 The OpenLDAP Foundation. + * Copyright 2008-2024 The OpenLDAP Foundation. * Portions Copyright 2008 Pierangelo Masarati, SysNet * All rights reserved. * diff --git a/clients/tools/ldapvc.c b/clients/tools/ldapvc.c index 264f293..e359611 100644 --- a/clients/tools/ldapvc.c +++ b/clients/tools/ldapvc.c @@ -2,7 +2,7 @@ /* $OpenLDAP$ */ /* This work is part of OpenLDAP Software <http://www.openldap.org/>. * - * Copyright 1998-2022 The OpenLDAP Foundation. + * Copyright 1998-2024 The OpenLDAP Foundation. * Portions Copyright 2010 Kurt D. Zeilenga. * All rights reserved. * diff --git a/clients/tools/ldapwhoami.c b/clients/tools/ldapwhoami.c index e8ac4b3..be1f813 100644 --- a/clients/tools/ldapwhoami.c +++ b/clients/tools/ldapwhoami.c @@ -2,7 +2,7 @@ /* $OpenLDAP$ */ /* This work is part of OpenLDAP Software <http://www.openldap.org/>. * - * Copyright 1998-2022 The OpenLDAP Foundation. + * Copyright 1998-2024 The OpenLDAP Foundation. * Portions Copyright 1998-2003 Kurt D. Zeilenga. * Portions Copyright 1998-2001 Net Boolean Incorporated. * Portions Copyright 2001-2003 IBM Corporation. |