gnupg (6 files)

cvs user wk cvs at cvs.gnupg.org
Mon Jul 18 19:32:41 CEST 2005


    Date: Monday, July 18, 2005 @ 19:58:25
  Author: wk
    Path: /cvs/gnupg/gnupg

Modified: THANKS TODO g10/ChangeLog g10/tdbio.c util/ChangeLog
          util/ttyio.c

* tdbio.c (open_db): Check for EROFS.  Suggested by Bryce Nichols.

* ttyio.c (do_get): Move printing of the prompt after disabling
echo.  Suggested by Scott Worley.


----------------+
 THANKS         |    2 ++
 TODO           |    8 --------
 g10/ChangeLog  |    4 ++++
 g10/tdbio.c    |    6 +++++-
 util/ChangeLog |    5 +++++
 util/ttyio.c   |   11 ++++++++++-
 6 files changed, 26 insertions(+), 10 deletions(-)


Index: gnupg/THANKS
diff -u gnupg/THANKS:1.84 gnupg/THANKS:1.85
--- gnupg/THANKS:1.84	Mon Jun 20 19:03:27 2005
+++ gnupg/THANKS	Mon Jul 18 19:58:25 2005
@@ -20,6 +20,7 @@
 Brian Moore		   bem at cmc.net
 Brian Warner		   warner at lothar.com
 Bryan Fullerton 	   bryanf at samurai.com
+Bryce Nichols              bryce at bnichols.org
 Caskey L. Dickson	   caskey at technocage.com
 Cees van de Griend	   cees-list at griend.xs4all.nl
 Charles Levert		   charles at comm.polymtl.ca
@@ -184,6 +185,7 @@
 Sam Roberts		   sam at cogent.ca
 Sami Tolvanen              sami at tolvanen.com
 Sascha Kiefer              sk at intertivity.com
+Scott Worley               sworley at chkno.net
 Sean MacLennan		   seanm at netwinder.org
 Sebastian Klemke           packet at convergence.de
 Serge Munhoven		   munhoven at mema.ucl.ac.be
Index: gnupg/TODO
diff -u gnupg/TODO:1.178 gnupg/TODO:1.179
--- gnupg/TODO:1.178	Tue May 31 10:39:18 2005
+++ gnupg/TODO	Mon Jul 18 19:58:25 2005
@@ -1,11 +1,3 @@
-  * From: Nicolas Sierro 
-    Date: Thu, 17 Jun 2004 12:31:24 +0200
-    
-    I understand your concern regarding the GNU coding standards. In
-    zlib-1.2.1, apart from several bug fixes, the inflate code is about
-    20% faster and the crc32 code about 50% faster. Some memory leaks were
-    also fixed according to the ChangeLog.
-    
   * Using an expired key for signing should give an error message
     "expired key" and not "unusable key'.  Furthermore the error should
     also be thrown when the default key has expired.  Reported by
Index: gnupg/g10/ChangeLog
diff -u gnupg/g10/ChangeLog:1.762 gnupg/g10/ChangeLog:1.763
--- gnupg/g10/ChangeLog:1.762	Sat Jul  9 04:34:04 2005
+++ gnupg/g10/ChangeLog	Mon Jul 18 19:58:25 2005
@@ -1,3 +1,7 @@
+2005-07-18  Werner Koch  <wk at g10code.com>
+
+	* tdbio.c (open_db): Check for EROFS.  Suggested by Bryce Nichols.
+
 2005-07-08  David Shaw  <dshaw at jabberwocky.com>
 
 	* trustdb.c (clean_uids_from_key): Don't keep a valid selfsig
Index: gnupg/g10/tdbio.c
diff -u gnupg/g10/tdbio.c:1.54 gnupg/g10/tdbio.c:1.55
--- gnupg/g10/tdbio.c:1.54	Tue May 31 10:39:15 2005
+++ gnupg/g10/tdbio.c	Mon Jul 18 19:58:25 2005
@@ -592,7 +592,11 @@
     log_fatal( _("can't lock `%s'\n"), db_name );
 #endif /* __riscos__ */
   db_fd = open (db_name, O_RDWR | MY_O_BINARY );
-  if (db_fd == -1 && errno == EACCES) {
+  if (db_fd == -1 && (errno == EACCES
+#ifdef EROFS
+                      || errno == EROFS)
+#endif
+      ) {
       db_fd = open (db_name, O_RDONLY | MY_O_BINARY );
       if (db_fd != -1)
           log_info (_("NOTE: trustdb not writable\n"));
Index: gnupg/util/ChangeLog
diff -u gnupg/util/ChangeLog:1.195 gnupg/util/ChangeLog:1.196
--- gnupg/util/ChangeLog:1.195	Thu Jun 23 06:23:37 2005
+++ gnupg/util/ChangeLog	Mon Jul 18 19:58:25 2005
@@ -1,3 +1,8 @@
+2005-07-18  Werner Koch  <wk at g10code.com>
+
+	* ttyio.c (do_get): Move printing of the prompt after disabling
+	echo.  Suggested by Scott Worley.
+
 2005-06-23  David Shaw  <dshaw at jabberwocky.com>
 
 	* http.c (make_radix64_string): Add '=' padding as per standard.
Index: gnupg/util/ttyio.c
diff -u gnupg/util/ttyio.c:1.37 gnupg/util/ttyio.c:1.38
--- gnupg/util/ttyio.c:1.37	Tue May 31 10:38:45 2005
+++ gnupg/util/ttyio.c	Mon Jul 18 19:58:25 2005
@@ -397,7 +397,6 @@
 	init_ttyfp();
 
     last_prompt_len = 0;
-    tty_printf( "%s", prompt );
     buf = m_alloc(n=50);
     i = 0;
 
@@ -405,6 +404,8 @@
     if( hidden )
 	SetConsoleMode(con.in, HID_INPMODE );
 
+    tty_printf( "%s", prompt );
+
     for(;;) {
 	DWORD nread;
 
@@ -436,6 +437,7 @@
 	SetConsoleMode(con.in, DEF_INPMODE );
 
 #elif defined(__riscos__)
+    tty_printf( "%s", prompt );
     do {
         c = riscos_getchar();
         if (c == 0xa || c == 0xd) { /* Return || Enter */
@@ -490,6 +492,8 @@
 #endif
     }
 
+    tty_printf( "%s", prompt );
+
     /* fixme: How can we avoid that the \n is echoed w/o disabling
      * canonical mode - w/o this kill_prompt can't work */
     while( read(fileno(ttyfp), cbuf, 1) == 1 && *cbuf != '\n' ) {
@@ -503,6 +507,11 @@
 	else if( c > 0xa0 )
 	    ; /* we don't allow 0xa0, as this is a protected blank which may
 	       * confuse the user */
+        /* Fixme: The above assumption is not bad.  We assum a certain
+           character set and even worse, the W32 version behaves
+           differently.  It is not clear how we can hix this.  When
+           used for passphrases this code path strips off certain
+           characters so changing this might invalidate passphrases.  */
 	else if( iscntrl(c) )
 	    continue;
 	if( !(i < n-1) ) {




More information about the Gnupg-commits mailing list