1 /* delete.c - shell backend delete function */
6 #include <sys/socket.h>
18 struct shellinfo *si = (struct shellinfo *) be->be_private;
21 if ( si->si_delete == NULL ) {
22 send_ldap_result( conn, op, LDAP_UNWILLING_TO_PERFORM, NULL,
23 "delete not implemented" );
27 if ( (op->o_private = forkandexec( si->si_delete, &rfp, &wfp ))
29 send_ldap_result( conn, op, LDAP_OPERATIONS_ERROR, NULL,
30 "could not fork/exec" );
34 /* write out the request to the delete process */
35 fprintf( wfp, "DELETE\n" );
36 fprintf( wfp, "msgid: %d\n", op->o_msgid );
37 print_suffixes( wfp, be );
38 fprintf( wfp, "dn: %s\n", dn );
41 /* read in the results and send them along */
42 read_and_send_results( be, conn, op, rfp, NULL, 0 );