r6149: Fixes bugs #2498 and 2484.
[obnox/samba/samba-obnox.git] / source3 / libads / ldap_printer.c
index 68e6735891038a1de49a390e0cc6e8abb8189605..61275e40d11de997f7c71c1c83b8ef09e9a2725e 100644 (file)
@@ -61,8 +61,10 @@ ADS_STATUS ads_find_printers(ADS_STRUCT *ads, void **res)
 
        /* For the moment only display all printers */
 
-       ldap_expr = "(&(!(showInAdvancedViewOnly=TRUE))(uncName=*)"
-               "(objectCategory=printQueue))";
+       ldap_expr =
+                CONST_DISCARD(char *,
+                                "(&(!(showInAdvancedViewOnly=TRUE))(uncName=*)"
+                                "(objectCategory=printQueue))");
 
        return ads_search(ads, res, ldap_expr, attrs);
 }