Browse Source

muffle `may be used uninitialized' warnings

pre-master-46
rlar 16 years ago
parent
commit
fe696310d6
  1. 4
      ChangeLog
  2. 19
      src/frontend/plotting/x11.c

4
ChangeLog

@ -1,3 +1,7 @@
2010-07-24 Robert Larice
* src/frontend/plotting/x11.c :
muffle `may be used uninitialized' warnings
2010-07-24 Robert Larice 2010-07-24 Robert Larice
* src/spicelib/devices/bsim3soi/b4soi.c , * src/spicelib/devices/bsim3soi/b4soi.c ,
* src/spicelib/devices/bsim3soi/b4soiacld.c , * src/spicelib/devices/bsim3soi/b4soiacld.c ,

19
src/frontend/plotting/x11.c

@ -829,8 +829,6 @@ zoomin(GRAPH *graph)
void void
hardcopy(Widget w, caddr_t client_data, caddr_t call_data) hardcopy(Widget w, caddr_t client_data, caddr_t call_data)
{ {
X11devdep tempdevdep;
Bool hasdevdep = FALSE;
/* com_hardcopy() -> gr_resize() -> setcolor() dirung postscript /* com_hardcopy() -> gr_resize() -> setcolor() dirung postscript
printing will act on currentgraph with a DEVDEP inherited from PSdevdep. printing will act on currentgraph with a DEVDEP inherited from PSdevdep.
But currentgraph had not changed its devdep, which was derived from But currentgraph had not changed its devdep, which was derived from
@ -838,16 +836,17 @@ hardcopy(Widget w, caddr_t client_data, caddr_t call_data)
temporary remedy, until there will be a cleanup of graph handling. E.g. temporary remedy, until there will be a cleanup of graph handling. E.g.
CopyGraph() does not make a copy of its devdep, but just copies the pointer, CopyGraph() does not make a copy of its devdep, but just copies the pointer,
so keeping the old devdep. */ so keeping the old devdep. */
lasthardcopy = (GRAPH *) client_data;
if (currentgraph->devdep) { if (currentgraph->devdep) {
tempdevdep = DEVDEP(currentgraph);
hasdevdep = TRUE;
X11devdep tempdevdep = DEVDEP(currentgraph);
com_hardcopy(NULL);
DEVDEP(currentgraph) = tempdevdep;
} else {
com_hardcopy(NULL);
currentgraph->devdep = NULL;
} }
lasthardcopy = (GRAPH *) client_data;
com_hardcopy(NULL);
if (hasdevdep)
DEVDEP(currentgraph) = tempdevdep;
else
currentgraph->devdep = NULL;
} }
void void

Loading…
Cancel
Save