(get_frame_size) [VMS]: Use a fresh i/o channel.
authorThien-Thi Nguyen <ttn@gnuvola.org>
Sun, 1 May 2005 11:34:54 +0000 (11:34 +0000)
committerThien-Thi Nguyen <ttn@gnuvola.org>
Sun, 1 May 2005 11:34:54 +0000 (11:34 +0000)
src/ChangeLog
src/sysdep.c

index 8c40923..47d2485 100644 (file)
@@ -1,3 +1,7 @@
+2005-05-01  Thien-Thi Nguyen  <ttn@gnu.org>
+
+       * sysdep.c (get_frame_size) [VMS]: Use a fresh i/o channel.
+
 2005-04-30  Richard M. Stallman  <rms@gnu.org>
 
        * fileio.c (Ffind_file_name_handler): Handle the `operations'
index e7494a2..42179d9 100644 (file)
@@ -1718,10 +1718,16 @@ get_frame_size (widthp, heightp)
 #else
 #ifdef VMS
 
+  /* Use a fresh channel since the current one may have stale info
+     (for example, from prior to a suspend); and to avoid a dependency
+     in the init sequence.  */
+  int chan;
   struct sensemode tty;
 
-  SYS$QIOW (0, input_fd, IO$_SENSEMODE, &tty, 0, 0,
-           &tty.class, 12, 0, 0, 0, 0);
+  SYS$ASSIGN (&input_dsc, &chan, 0, 0);
+  SYS$QIOW (0, chan, IO$_SENSEMODE, &tty, 0, 0,
+            &tty.class, 12, 0, 0, 0, 0);
+  SYS$DASSGN (chan);
   *widthp = tty.scr_wid;
   *heightp = tty.scr_len;