Browse Source

minor rewrite, avoid type conversion warnings

pre-master-46
rlar 16 years ago
parent
commit
927470e12f
  1. 5
      ChangeLog
  2. 8
      src/frontend/subckt.c
  3. 3
      src/spicelib/parser/inppas2.c

5
ChangeLog

@ -1,3 +1,8 @@
2010-11-06 Robert Larice
* src/frontend/subckt.c ,
* src/spicelib/parser/inppas2.c :
minor rewrite, avoid type conversion warnings
2010-11-06 Robert Larice
* src/spicelib/devices/bsim1/b1.c ,
* src/spicelib/devices/bsim1/b1dset.c ,

8
src/frontend/subckt.c

@ -1491,7 +1491,9 @@ numnodes(char *name)
while (*name && isspace(*name))
name++;
c = (isupper(*name) ? tolower(*name) : *name);
c = *name;
if(isupper(c))
c = (char) tolower(c);
(void) strncpy(buf, name, sizeof(buf));
s = buf;
@ -1721,7 +1723,9 @@ devmodtranslate(struct line *deck, char *subname)
while (*t && isspace(*t))
t++;
c = isupper(*t) ? tolower(*t) : *t; /* set c to first char in line. . . . */
c = *t; /* set c to first char in line. . . . */
if(isupper(c))
c = (char) tolower(c);
found = FALSE;
buffer = TMALLOC(char, strlen(t) + strlen(subname) + 4);

3
src/spicelib/parser/inppas2.c

@ -91,7 +91,8 @@ void INPpas2(CKTcircuit *ckt, card * data, INPtables * tab, TSKtask *task)
#endif
c = *(current->line);
c = islower(c) ? toupper(c) : c;
if(islower(c))
c = (char) toupper(c);
switch (c) {

Loading…
Cancel
Save