Imported Upstream version 1.8.4p4
[debian/sudo] / src / conversation.c
index fa40f791a0434174c477a8c18fb417c5ac038c1c..a2dab5a7c385b142a81ee69fe8f6af65583c4241 100644 (file)
 
 #include "sudo.h"
 #include "sudo_plugin.h"
+#include "sudo_plugin_int.h"
 
 extern int tgetpass_flags; /* XXX */
 
+#if defined(HAVE_DLOPEN) || defined(HAVE_SHL_LOAD)
+sudo_conv_t sudo_conv; /* NULL in sudo front-end */
+#endif
+
 /*
  * Sudo conversation function.
  */
@@ -91,6 +96,10 @@ sudo_conversation(int num_msgs, const struct sudo_conv_message msgs[],
                if (msg->msg)
                    (void) fputs(msg->msg, stderr);
                break;
+           case SUDO_CONV_DEBUG_MSG:
+               if (msg->msg)
+                   sudo_debug_write(msg->msg, strlen(msg->msg));
+               break;
            default:
                goto err;
        }