From ce9d86a278cf8e57fd8253d5758d339f62cc2683 Mon Sep 17 00:00:00 2001 From: Hallvard Furuseth Date: Tue, 9 Mar 1999 05:53:21 +0000 Subject: [PATCH] Check for directory separator `\' in program name, by JR Heisey --- clients/tools/ldapmodify.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/clients/tools/ldapmodify.c b/clients/tools/ldapmodify.c index 4dde46f967..08db8c5912 100644 --- a/clients/tools/ldapmodify.c +++ b/clients/tools/ldapmodify.c @@ -95,7 +95,8 @@ main( int argc, char **argv ) FILE *fp; int rc, i, use_ldif, authmethod, version, want_bindpw, debug; - if (( prog = strrchr( argv[ 0 ], '/' )) == NULL ) { + if (( prog = strrchr( argv[ 0 ], '/' )) == NULL && + ( prog = strrchr( argv[ 0 ], '\\' )) == NULL ) { // for Windows/DOS prog = argv[ 0 ]; } else { ++prog; -- 2.39.5