aboutsummaryrefslogtreecommitdiffstats
path: root/g10
diff options
context:
space:
mode:
Diffstat (limited to 'g10')
-rw-r--r--g10/ChangeLog6
-rw-r--r--g10/gpg.c12
2 files changed, 18 insertions, 0 deletions
diff --git a/g10/ChangeLog b/g10/ChangeLog
index ecfb3db9f..d812cfd42 100644
--- a/g10/ChangeLog
+++ b/g10/ChangeLog
@@ -1,3 +1,9 @@
+2011-09-12 Werner Koch <[email protected]>
+
+ * gpg.c [__VMS]: Include vms.h.
+ (main) [__VMS]: Init batch mode according to actual process mode.
+ Suggested by Steven M. Schweda.
+
2011-08-09 Werner Koch <[email protected]>
* keyedit.c (show_key_with_all_names): Remove unused var.
diff --git a/g10/gpg.c b/g10/gpg.c
index 28841c0aa..019079047 100644
--- a/g10/gpg.c
+++ b/g10/gpg.c
@@ -39,6 +39,9 @@
#ifdef HAVE_W32_SYSTEM
#include <windows.h>
#endif
+#ifdef __VMS
+# include "vms.h"
+#endif
#define INCLUDED_BY_MAIN_MODULE 1
#include "packet.h"
@@ -1872,6 +1875,15 @@ main (int argc, char **argv )
opt.lock_once = 1;
#endif /* __riscos__ */
+#ifdef __VMS
+ /* On VMS, set the default value of the "--[no-]batch" flag
+ * according to the actual process mode. The user can override
+ * this with an explicit command-line "--[no-]batch" option. This
+ * avoids that the process stops while trying to initialize the
+ * tty in batch mode. */
+ opt.batch = batch_mode_vms();
+#endif
+
reopen_std();
trap_unaligned();
secmem_set_flags( secmem_get_flags() | 2 ); /* suspend warnings */