OSDN Git Service

2000-08-08 Fernando Nasser <fnasser@cygnus.com>
authorFernando Nasser <fnasser@redhat.com>
Tue, 8 Aug 2000 22:14:16 +0000 (22:14 +0000)
committerFernando Nasser <fnasser@redhat.com>
Tue, 8 Aug 2000 22:14:16 +0000 (22:14 +0000)
* srctxtwin.itb (LoadFromCache): Do not cache if cannot stat the file.
This lead to problems trying to access a incomplete cache entry later.

gdb/gdbtk/library/ChangeLog
gdb/gdbtk/library/srctextwin.itb

index 27b21b5..8530112 100644 (file)
@@ -1,3 +1,8 @@
+2000-08-08  Fernando Nasser  <fnasser@cygnus.com>
+
+       * srctxtwin.itb (LoadFromCache): Do not cache if cannot stat the file.
+       This lead to problems trying to access a incomplete cache entry later.
+
 2000-06-06  Fernando Nasser  <fnasser@cygnus.com>
 
         * util.tcl (find_iwidgets_library): Add missing global declaration
index 023228d..2c209f1 100644 (file)
@@ -2489,7 +2489,6 @@ body SrcTextWin::LoadFromCache {w name asm lib} {
 
   } else {
     debug "name=$name"
-    set Stwc($full_name:pane) pane$filenum
     # If we are trying to load a source file, check the time
     # to see if we need to update it.  If we can't stat the
     # file then we probably can't open it either, so error 
@@ -2500,6 +2499,7 @@ body SrcTextWin::LoadFromCache {w name asm lib} {
        debug "Could not stat file \"$name\" - \"$file_time\""
        return -1
       } else {
+        set Stwc($full_name:pane) pane$filenum
        set Stwc($name:mtime) $file_time
       }    
     } else {
@@ -2507,7 +2507,8 @@ body SrcTextWin::LoadFromCache {w name asm lib} {
       # check whether the executable is newer than the cached
       # disassembly.  For mixed files, we need to check BOTH
       # the source file mtime, and the executable time.
-
+      
+      set Stwc($full_name:pane) pane$filenum
       set Stwc($name:mtime) 0
     }