]> git.sur5r.net Git - openldap/blobdiff - libraries/librewrite/info.c
Merge remote branch 'origin/mdb.master'
[openldap] / libraries / librewrite / info.c
index 32b5544ebf08dbc21068374863126f4702e5acc0..7ff1e45441a9a49c3f223df68f2957e93bcefea3 100644 (file)
@@ -1,7 +1,7 @@
 /* $OpenLDAP$ */
 /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
  *
- * Copyright 2000-2005 The OpenLDAP Foundation.
+ * Copyright 2000-2011 The OpenLDAP Foundation.
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -216,7 +216,7 @@ rewrite_session(
 
                case REWRITE_MODE_COPY_INPUT:
                        *result = strdup( string );
-                       rc = REWRITE_REGEXEC_OK;
+                       rc = ( *result != NULL ) ? REWRITE_REGEXEC_OK : REWRITE_REGEXEC_ERR;
                        goto rc_return;
 
                case REWRITE_MODE_USE_DEFAULT: