From lswhbcb at hotmail.com Sat Jul 7 20:53:15 2007 From: lswhbcb at hotmail.com (lw) Date: Sat Jul 7 20:54:31 2007 Subject: [splint-discuss] splint lib problem? Message-ID: I am a new to splint. i lint clean my project with the includes header. #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include ================================================================>>>> i use posixlib flag with splint. splint outputs: src/pub_inet.c:26:17: Unrecognized identifier: socket Identifier used in code has not been declared. (Use -unrecog to in bit warning) src/pub_inet.c:26:26: Unrecognized identifier: AF_INET src/pub_inet.c:26:35: Unrecognized identifier: SOCK_DGRAM src/pub_inet.c:29:25: Unrecognized identifier: caddr_t ================================================================>>>> if using unixlib, splint outputs: src/pub_inet.c: (in function GetNetIfInfo)src/pub_inet.c:30:27: Unrecognized identifier: SIOCGIFCONF Identifier used in code has not been declared. (Use -unrecog to inhibit warning)src/pub_inet.c:38:29: Unrecognized identifier: SIOCGIFFLAGSsrc/pub_inet.c:39:69: Unrecognized identifier: IFF_UPsrc/pub_inet.c:40:37: Unrecognized identifier: SIOCGIFADDRsrc/pub_inet.c: (in function GetLocalIP)src/pub_inet.c:61:12: Unsafe in multithreaded applications, use gethostbyname_r instead: gethostbyname Non-reentrant function should not be used in multithreaded code. (Use -multithreaded to inhibit warning)src/pub_inet.c:65:47: Arrow access from possibly null pointer host: host->h_addr_list A possibly null pointer is dereferenced. Value is either the result of a function which may return null (in which case, code should check it is not null), or a global, parameter or structure field declared with the null qualifier. (Use -nullderef to inhibit warning) src/pub_inet.c:61:12: Storage host may become nullsrc/pub_inet.c: (in function IcmpCheckSum)src/pub_inet.c:96:13: Left operand of >> may be negative (int): sum >> 16 The left operand to a shift operator may be negative (behavior is implementation-defined). (Use -shiftimplementation to inhibit warning)src/pub_inet.c:97:14: Left operand of >> may be negative (int): sum >> 16src/pub_inet.c: (in function IcmpPacking)src/pub_inet.c:111:23: Unrecognized identifier: ICMP_ECHOsrc/pub_inet.c: (in function IcmpUnPack)src/pub_inet.c:156:31: Unrecognized identifier: ICMP_ECHOREPLYsrc/pub_inet.c: (in function IcmpRecv)src/pub_inet.c:214:16: Variable errno shadows outer declaration An outer declaration is shadowed by the local declaration. (Use -shadow to inhibit warning) load file unix.lcd: Specification of errno: intsrc/pub_inet.c: (in function PingInit)src/pub_inet.c:244:29: Unrecognized identifier: getprotobynamesrc/pub_inet.c:244:12: Implicitly only storage pIS->pProtoent (type struct protoent *) not released before assig nment: pIS->pProtoent = getprotobyname("icmp") A memory leak has been detected. Only-qualified storage is not released before the last reference to it is lost. (Use -mustfreeonly to inhibit warning)src/pub_inet.c:256:2: Path with no return in function declared to return int There is a path through a function declared to return a value on which there is no return statement. This means the execution may fall through without returning a meaningful result to the caller. (Use -noret to inhibit warning)src/pub_inet.c: (in function PingStart)src/pub_inet.c:274:10: Comparison of unsigned value involving zero: (pIS->wSockfd = socket(AF_INET, SOCK_RAW, pIS->pProtoent->p_proto)) < 0 An unsigned value is used in a comparison with zero in a way that is either a bug or confusing. (Use -unsignedcompare to inhibit warning)src/pub_inet.c:289:17: Unrecognized identifier: inet_addrsrc/pub_inet.c:290:23: Unrecognized identifier: INADDR_NONEsrc/pub_inet.c:292:24: Unsafe in multithreaded applications, use gethostbyname_r instead: gethostbynamesrc/pub_inet.c:311:2: Path with no return in function declared to return intsrc/pub_inet.c: (in function PingTimer)src/pub_inet.c:340:2: Path with no return in function declared to return int Splinting: pub_log.c please wait ...src/pub_log.c: (in function TxtColor)src/pub_log.c:76:27: Possibly null storage p passed as non-null param: strcpy (..., p) A possibly null pointer is passed as a parameter corresponding to a formal parameter with no /*@null@*/ annotation. If NULL may be used for this parameter, add a /*@null@*/ annotation to the function parameter declaration. (Use -nullpass to inhibit warning) src/pub_log.c:65:18: Storage p may become null ================================================================>>>>if using +nolib +nof -warnposix +load /usr/share/splint/lib/unixstrict.lcd ,splint outputs: src/pub_inet.c: (in function GetNetIfInfo)src/pub_inet.c:26:17: Called procedure socket may access global errno A checked global variable is used in the function, but not listed in its globals clause. By default, only globals specified in .lcl files are checked. To check all globals, use +allglobals. To check globals selectively use /*@checked@*/ in the global declaration. (Use -globs to inhibit warning)src/pub_inet.c:30:27: Unrecognized identifier: SIOCGIFCONF Identifier used in code has not been declared. (Use -unrecog to inhibit warning)src/pub_inet.c:30:15: Called procedure ioctl may access global errnosrc/pub_inet.c:38:29: Unrecognized identifier: SIOCGIFFLAGSsrc/pub_inet.c:38:17: Called procedure ioctl may access global errnosrc/pub_inet.c:39:69: Unrecognized identifier: IFF_UPsrc/pub_inet.c:40:37: Unrecognized identifier: SIOCGIFADDRsrc/pub_inet.c:40:25: Called procedure ioctl may access global errnosrc/pub_inet.c:50:5: Called procedure close may access global errnosrc/pub_inet.c: (in function GetLocalIP)src/pub_inet.c:61:12: Unsafe in multithreaded applications, use gethostbyname_r instead: gethostbyname Non-reentrant function should not be used in multithreaded code. (Use -multithreaded to inhibit warning)src/pub_inet.c:65:47: Arrow access from possibly null pointer host: host->h_addr_list A possibly null pointer is dereferenced. Value is either the result of a function which may return null (in which case, code should check it is not null), or a global, parameter or structure field declared with the null qualifier. (Use -nullderef to inhibit warning) src/pub_inet.c:61:12: Storage host may become nullsrc/pub_inet.c: (in function IcmpCheckSum)src/pub_inet.c:96:13: Left operand of >> may be negative (int): sum >> 16 The left operand to a shift operator may be negative (behavior is implementation-defined). (Use -shiftimplementation to inhibit warning)src/pub_inet.c:97:14: Left operand of >> may be negative (int): sum >> 16src/pub_inet.c: (in function IcmpPacking)src/pub_inet.c:111:23: Unrecognized identifier: ICMP_ECHOsrc/pub_inet.c:120:5: Called procedure gettimeofday may access global errnosrc/pub_inet.c: (in function IcmpUnPack)src/pub_inet.c:137:5: Called procedure gettimeofday may access global errnosrc/pub_inet.c:156:31: Unrecognized identifier: ICMP_ECHOREPLYsrc/pub_inet.c: (in function IcmpStatis)src/pub_inet.c:182:5: Called procedure close may access global errnosrc/pub_inet.c: (in function IcmpSend)src/pub_inet.c:197:14: Called procedure sendto may access global errnosrc/pub_inet.c:201:13: Called procedure perror may access global errnosrc/pub_inet.c: (in function IcmpRecv)src/pub_inet.c:214:16: Variable errno shadows outer declaration An outer declaration is shadowed by the local declaration. (Use -shadow to inhibit warning) load file /usr/share/splint/lib/unixstrict.lcd: Specification of errno: intsrc/pub_inet.c:220:16: Called procedure recvfrom may access global errnosrc/pub_inet.c:228:13: Called procedure perror may access global errnosrc/pub_inet.c: (in function PingInit)src/pub_inet.c:244:29: Unrecognized identifier: getprotobynamesrc/pub_inet.c:244:12: Implicitly only storage pIS->pProtoent (type struct protoent *) not released before assignment: pIS->pProtoent = getprotobyname("icmp") A memory leak has been detected. Only-qualified storage is not released before the last reference to it is lost. (Use -mustfreeonly to inhibit warning)src/pub_inet.c:246:9: Called procedure perror may access global errnosrc/pub_inet.c:251:5: Called procedure setuid may access global errnosrc/pub_inet.c:256:2: Path with no return in function declared to return int There is a path through a function declared to return a value on which there is no return statement. This means the execution may fall through without returning a meaningful result to the caller. (Use -noret to inhibit warning)src/pub_inet.c: (in function PingStart)src/pub_inet.c:275:12: Called procedure socket may access global errnosrc/pub_inet.c:274:10: Comparison of unsign ed value involving zero: (pIS->wSockfd = socket(AF_INET, SOCK_RAW, pIS->pProtoent->p_proto)) < 0 An unsigned value is used in a comparison with zero in a way that is either a bug or confusing. (Use -unsignedcompare to inhibit warning)src/pub_inet.c:277:9: Called procedure perror may access global errnosrc/pub_inet.c:283:5: Called procedure setsockopt may access global errnosrc/pub_inet.c:289:17: Unrecognized identifier: inet_addrsrc/pub_inet.c:290:23: Unrecognized identifier: INADDR_NONEsrc/pub_inet.c:292:24: Unsafe in multithreaded applications, use gethostbyname_r instead: gethostbynamesrc/pub_inet.c:294:13: Called procedure perror may access global errnosrc/pub_inet.c:311:2: Path with no return in function declared to return intsrc/pub_inet.c: (in function PingTimer)src/pub_inet.c:340:2: Path with no return in function declared to return int Splinting: pub_log.c please wait ...src/pub_log.c: (in function TxtColor)src/pub_log.c:76:27: Possibly null storage p passed as non-null param: strcpy (..., p) A possibly null pointer is passed as a parameter corresponding to a formal parameter with no /*@null@*/ annotation. If NULL may be used for this parameter, add a /*@null@*/ annotation to the function parameter declaration. (Use -nullpass to inhibit warning) src/pub_log.c:65:18: Storage p may become null Splinting: pub_malloc.c please wait ...Splinting: pub_netcap.c please wait ...src/pub_netcap.c: (in function NcGetSocket)src/pub_netcap.c:74:20: Called procedure socket may access global errno A checked global variable is used in the function, but not listed in its globals clause. By default, only globals specified in .lcl files are checked. To check all globals, use +allglobals. To check globals selectively use /*@checked@*/ in the global declaration. (Use -globs to inhibit warning)src/pub_netcap.c:76:9: Called procedure perror may access global errnosrc/pub_netcap.c:80:5: Called procedure setsockopt may access global errnosrc/pub_netcap.c:82:20: Unrecognized identifier: FIONBIO Identifier used in code has not been declared. (Use -unrecog to inhibit warning)src/pub_netcap.c:82:5: Called procedure ioctl may access global errnosrc/pub_netcap.c: (in function NcInit)src/pub_netcap.c:101:18: Unrecognized identifier: inet_addrsrc/pub_netcap.c: (in function NcStop)src/pub_netcap.c:118:5: Called procedure shutdown may access global errnosrc/pub_netcap.c: (in function NcMtp3Send)src/pub_netcap.c:269:5: Called procedure sendto may access global errnosrc/pub_netcap.c: (in function NcSccpSend)src/pub_netcap.c:332:10: Called procedure sendto may access global errnosrc/pub_netcap.c:336:9: Called procedure perror may access global errno ================================================================>>>>if i make a fake file (copy from /usr/include/sys/socket.h) in -I./splint , ignore the file with /*@ignore@*/ /*@end@*/ inthe "socket.h " [[[[ I do not know why the flag "/*@ignore@*/" is not acted well.!!!??? ]]]]: includes.h: ....ifdef S_SPLINT_S //#include #include "./splint/socket.h" //#include #else #include #endif... the splint outputs: src/include/splint/socket.h:49:5: Parse Error: Non-function declaration: __BEGIN_DECLS : int. (For help on parse errors, see splint -help parseerrors.) =====================================================>>>>i have on ideas. Who can help me fix the problem ? thanks a lot. MSN:lswhbcb@hotmail.com _________________________________________________________________ ?? Live.com ??????????????????? http://www.live.com/getstarted.aspx -------------- next part -------------- An HTML attachment was scrubbed... URL: http://www.cs.Virginia.EDU/pipermail/splint-discuss/attachments/20070708/41ef5d7b/attachment-0001.html From lswhbcb at hotmail.com Sat Jul 7 21:17:10 2007 From: lswhbcb at hotmail.com (lw) Date: Sat Jul 7 21:17:25 2007 Subject: [splint-discuss] splint lib problem? Message-ID: sorry, the mail does not look well sent from hotmail to splint maillist. Please see the problem on URL: http://www.linuxquestions.org/questions/showthread.php?p=2814794#post2814794 Thx _________________________________________________________________ ?????????? http://search.msn.com/results.aspx?q=%E4%B8%AD%E5%9B%BD%E5%8D%81%E5%A4%A7%E9%A3%8E%E6%99%AF&mkt=zh-CN&form=QBRE -------------- next part -------------- An HTML attachment was scrubbed... URL: http://www.cs.Virginia.EDU/pipermail/splint-discuss/attachments/20070708/7c511a2f/attachment.html From ajay.goel at bhartitelesoft.com Mon Jul 9 20:37:04 2007 From: ajay.goel at bhartitelesoft.com (Ajay Goel) Date: Mon Jul 9 20:37:57 2007 Subject: [splint-discuss] Prolem in running splint on directory structure Message-ID: Hi All, I am a new to splint. I have all my source code in following directory structure: Project \inc \*.h and Project \src \p1 \*.c and Project \src \*.c 1. I am not able to find out the way by which i can check all my code in directory and its subdirectory. 2. For a single c file i have tried to include path using -I./Project/inc/ but it is not working for me. Please help me Thanks n Regards, Ajay Goel -------------- next part -------------- An HTML attachment was scrubbed... URL: http://www.cs.Virginia.EDU/pipermail/splint-discuss/attachments/20070710/5040b166/attachment.html From andy at petdance.com Fri Jul 13 08:24:36 2007 From: andy at petdance.com (Andy Lester) Date: Fri Jul 13 08:31:41 2007 Subject: [splint-discuss] Releasing 3.1.2 Message-ID: <1A3B51A8-AF7D-4D47-B3A8-2097814034C1@petdance.com> What would it take to get the CVS version of Splint released as 3.1.2? It fixes a number of bugs that I've run into as we use it on the Parrot project (http://parrotcode.org/). I'm using the CVS version from my own build, but I'd like the others on the project to not have to build their own. Thanks, xoxo, Andy -- Andy Lester => andy@petdance.com => www.petdance.com => AIM:petdance From evans at cs.virginia.edu Fri Jul 13 15:50:24 2007 From: evans at cs.virginia.edu (David Evans) Date: Fri Jul 13 15:50:44 2007 Subject: [splint-discuss] Releasing 3.1.2 In-Reply-To: <1A3B51A8-AF7D-4D47-B3A8-2097814034C1@petdance.com> References: <1A3B51A8-AF7D-4D47-B3A8-2097814034C1@petdance.com> Message-ID: <469801B0.2060204@cs.virginia.edu> Hi Andy, I've updated the source code distribution to 3.1.2 (which is posted now on splint.org), to incorporate the latest CVS version (with a few more minor fixes). The CVS code and source code distribution are now the same. Thanks for the prodding, I should have done this a long time ago... --- Dave Andy Lester wrote: > What would it take to get the CVS version of Splint released as 3.1.2? > It fixes a number of bugs that I've run into as we use it on the Parrot > project (http://parrotcode.org/). I'm using the CVS version from my own > build, but I'd like the others on the project to not have to build their > own. > > Thanks, > xoxo, > Andy > > -- > Andy Lester => andy@petdance.com => www.petdance.com => AIM:petdance > > > > > _______________________________________________ > splint-discuss mailing list > splint-discuss@ares.cs.Virginia.EDU > http://www.cs.Virginia.EDU/mailman-2.1.5/listinfo/splint-discuss From pkzc at freemail.hu Sun Jul 15 08:04:42 2007 From: pkzc at freemail.hu (=?ISO-8859-1?Q?Kozics_P=E9ter?=) Date: Sun Jul 15 08:04:38 2007 Subject: [splint-discuss] Releasing 3.1.2 In-Reply-To: <469801B0.2060204@cs.virginia.edu> References: <1A3B51A8-AF7D-4D47-B3A8-2097814034C1@petdance.com> <469801B0.2060204@cs.virginia.edu> Message-ID: <469A378A.4040804@freemail.hu> Hello Dave, Just as Andy, I have been using the CVS code for some time, it was labelled 3.1.1.2. In the tgz file of the 3.1.2, in config.h, I found the same string instead of 3.1.2, and the compiled program identifies itself as 3.1.1.2, which may be confusing in the future: $ ./bin/splint.exe Splint 3.1.1.2 --- 15 Jul 2007 Besides, for 3.1.1.2, I had to use two small patches, attached in the patch file. the first was necessary so that I can compile splint under cygwin. The second was necessary so that splint can parse correctly this (or something similar): v = +1; Please take a look at the patch, perhaps you could use it, because I think the 3.1.1.2/3.1.2 version string problem should be fixed anyway. best regards Peter David Evans wrote: > Hi Andy, > > I've updated the source code distribution to 3.1.2 (which is posted > now on splint.org), to incorporate the latest CVS version (with a few > more minor fixes). The CVS code and source code distribution are now > the same. > > Thanks for the prodding, I should have done this a long time ago... > > --- Dave > > Andy Lester wrote: >> What would it take to get the CVS version of Splint released as >> 3.1.2? It fixes a number of bugs that I've run into as we use it on >> the Parrot project (http://parrotcode.org/). I'm using the CVS >> version from my own build, but I'd like the others on the project to >> not have to build their own. >> >> Thanks, >> xoxo, >> Andy >> >> -- >> Andy Lester => andy@petdance.com => www.petdance.com => AIM:petdance >> >> >> >> >> _______________________________________________ >> splint-discuss mailing list >> splint-discuss@ares.cs.Virginia.EDU >> http://www.cs.Virginia.EDU/mailman-2.1.5/listinfo/splint-discuss > _______________________________________________ > splint-discuss mailing list > splint-discuss@ares.cs.Virginia.EDU > http://www.cs.Virginia.EDU/mailman-2.1.5/listinfo/splint-discuss > -------------- next part -------------- # # In your working directory you should have smtg like this: # # $ ll # total 16 # drwxr-xr-x 13 peter user 0 Sep 30 17:21 splint/ # -rw-r--r-- 1 peter user 535 Sep 30 17:55 splint_3.1.1.2-cygwin.patch # # and you are supposed to do this: # $ patch -p0 < splint_3.1.1.2-cygwin.patch # diff -aur splint/src/Headers/osd.h splint-cygwin/src/Headers/osd.h --- splint/src/Headers/osd.h 2003-04-22 04:25:52.000000000 +0200 +++ splint-cygwin/src/Headers/osd.h 2006-12-21 21:25:02.000000000 +0100 @@ -41,7 +41,7 @@ ** ** POSIX defines PATHMAX in limits.h */ - +#ifndef MAXPATHLEN # ifdef PATH_MAX /*@constant size_t MAXPATHLEN; @*/ # define MAXPATHLEN PATH_MAX @@ -49,6 +49,9 @@ /*@constant size_t MAXPATHLEN; @*/ # define MAXPATHLEN 1024 # endif +#endif + +typedef mode_t __mode_t; typedef enum { OSD_FILEFOUND, diff -aur splint/src/constraintGeneration.c splint-cygwin/src/constraintGeneration.c --- splint/src/constraintGeneration.c 2003-12-08 08:28:12.000000000 +0100 +++ splint-cygwin/src/constraintGeneration.c 2006-12-21 21:02:06.000000000 +0100 @@ -1398,7 +1398,7 @@ cons = constraint_makeMaxSetSideEffectPostDecrement (t1, sequencePoint); e->ensuresConstraints = constraintList_add (e->ensuresConstraints, cons); } - else if (lltok_isMult(tok )) + else if (lltok_isMult( tok )) { if (definatelv) { @@ -1424,6 +1424,10 @@ { break; } + else if (lltok_isPlus_Op (tok)) + { + break; + } else if (lltok_isMinus_Op (tok)) { break; From pkzc at freemail.hu Sun Jul 15 07:56:30 2007 From: pkzc at freemail.hu (=?ISO-8859-1?Q?Kozics_P=E9ter?=) Date: Sun Jul 15 08:27:15 2007 Subject: [splint-discuss] Releasing 3.1.2 In-Reply-To: <469801B0.2060204@cs.virginia.edu> References: <1A3B51A8-AF7D-4D47-B3A8-2097814034C1@petdance.com> <469801B0.2060204@cs.virginia.edu> Message-ID: <469A359E.9090203@freemail.hu> Hello Dave, Just as Andy, I have been using the CVS code for some time, it was labelled 3.1.1.2. In the tgz file of the 3.1.2, in config.h, I found the same string instead of 3.1.2, and the compiled program identifies itself as 3.1.1.2, which may be confusing in the future: $ ./bin/splint.exe Splint 3.1.1.2 --- 15 Jul 2007 Besides, for 3.1.1.2, I had to use two small patches, attached in the patch file. the first was necessary so that I can compile splint under cygwin. The second was necessary so that splint can parse correctly this (or something similar): v = +1; Please take a look at the patch, perhaps you could use it, because I think the 3.1.1.2/3.1.2 version string problem should be fixed anyway. best regards Peter David Evans wrote: > Hi Andy, > > I've updated the source code distribution to 3.1.2 (which is posted > now on splint.org), to incorporate the latest CVS version (with a few > more minor fixes). The CVS code and source code distribution are now > the same. > > Thanks for the prodding, I should have done this a long time ago... > > --- Dave > > Andy Lester wrote: >> What would it take to get the CVS version of Splint released as >> 3.1.2? It fixes a number of bugs that I've run into as we use it on >> the Parrot project (http://parrotcode.org/). I'm using the CVS >> version from my own build, but I'd like the others on the project to >> not have to build their own. >> >> Thanks, >> xoxo, >> Andy >> >> -- >> Andy Lester => andy@petdance.com => www.petdance.com => AIM:petdance >> >> >> >> >> _______________________________________________ >> splint-discuss mailing list >> splint-discuss@ares.cs.Virginia.EDU >> http://www.cs.Virginia.EDU/mailman-2.1.5/listinfo/splint-discuss > _______________________________________________ > splint-discuss mailing list > splint-discuss@ares.cs.Virginia.EDU > http://www.cs.Virginia.EDU/mailman-2.1.5/listinfo/splint-discuss > From elfring at users.sourceforge.net Sun Jul 15 08:38:29 2007 From: elfring at users.sourceforge.net (SF Markus Elfring) Date: Sun Jul 15 08:38:47 2007 Subject: [splint-discuss] Releasing 3.1.2 In-Reply-To: <469801B0.2060204@cs.virginia.edu> References: <1A3B51A8-AF7D-4D47-B3A8-2097814034C1@petdance.com> <469801B0.2060204@cs.virginia.edu> Message-ID: <469A3F75.8080506@users.sourceforge.net> > I've updated the source code distribution to 3.1.2 (which is posted > now on splint.org), to incorporate the latest CVS version (with a few > more minor fixes). The CVS code and source code distribution are now > the same. How many developers care to resolve the open issues (http://splint.org/bugs.html) in the software? Can its internal design be improved so that more participation would be possible by other interested programmers? Regards, Markus From andy at petdance.com Sun Jul 15 08:49:00 2007 From: andy at petdance.com (Andy Lester) Date: Sun Jul 15 08:56:25 2007 Subject: [splint-discuss] Moving to Google Code In-Reply-To: <469A3F75.8080506@users.sourceforge.net> References: <1A3B51A8-AF7D-4D47-B3A8-2097814034C1@petdance.com> <469801B0.2060204@cs.virginia.edu> <469A3F75.8080506@users.sourceforge.net> Message-ID: <0FCA4CEB-A169-407F-9059-29FA501A06F1@petdance.com> On Jul 15, 2007, at 10:38 AM, SF Markus Elfring wrote: > How many developers care to resolve the open issues (http:// > splint.org/bugs.html) in the software? > Can its internal design be improved so that more participation > would be possible by other interested programmers? I would be glad to help out however I can. If the open issues were moved to the bug tracker in SourceForge, it would make it easier to see what's what. It would also be far better to can the static page of "known bugs" and replace it with a searchable database. Better still, if the entire project were moved to Google Code, it would be a quantum leap forward in usability. You'd get a bug tracker that's usable, a wiki, and Subversion support instead of clunky old CVS. I realize that splint has been quiet for a while, but its value cannot be underestimated to projects still alive today. A move to Google Code would help re-energize this incredibly useful tool. xoxo, Andy -- Andy Lester => andy@petdance.com => www.petdance.com => AIM:petdance From evans at cs.virginia.edu Sun Jul 15 09:43:27 2007 From: evans at cs.virginia.edu (David Evans) Date: Sun Jul 15 09:43:44 2007 Subject: [splint-discuss] Moving to Google Code In-Reply-To: <0FCA4CEB-A169-407F-9059-29FA501A06F1@petdance.com> References: <1A3B51A8-AF7D-4D47-B3A8-2097814034C1@petdance.com> <469801B0.2060204@cs.virginia.edu> <469A3F75.8080506@users.sourceforge.net> <0FCA4CEB-A169-407F-9059-29FA501A06F1@petdance.com> Message-ID: <469A4EAF.5010700@cs.virginia.edu> Andy Lester wrote: > > On Jul 15, 2007, at 10:38 AM, SF Markus Elfring wrote: > >> How many developers care to resolve the open issues >> (http://splint.org/bugs.html) in the software? >> Can its internal design be improved so that more participation would >> be possible by other interested programmers? > ... > > I realize that splint has been quiet for a while, but its value cannot > be underestimated to projects still alive today. A move to Google Code > would help re-energize this incredibly useful tool. > Yes, splint has been stagnant for about 5 years now, but its great to hear people are still using it and interested in improving it. I don't have any plans to work on it, and it is unlikely I'll be able to spend the time needed to re-energize things. I believe the only way significant improvements will happen is if someone volunteers to lead and manage the effort. If someone wants to do this, I would be happy to help out getting things started and pass on "ownership" of the code. Any brave volunteers? --- Dave From andy at petdance.com Sun Jul 15 10:03:24 2007 From: andy at petdance.com (Andy Lester) Date: Sun Jul 15 10:04:10 2007 Subject: [splint-discuss] Moving to Google Code In-Reply-To: <469A4EAF.5010700@cs.virginia.edu> References: <1A3B51A8-AF7D-4D47-B3A8-2097814034C1@petdance.com> <469801B0.2060204@cs.virginia.edu> <469A3F75.8080506@users.sourceforge.net> <0FCA4CEB-A169-407F-9059-29FA501A06F1@petdance.com> <469A4EAF.5010700@cs.virginia.edu> Message-ID: On Jul 15, 2007, at 11:43 AM, David Evans wrote: > I believe the only way significant improvements will happen is if > someone volunteers to lead and manage the effort. If someone wants > to do this, I would be happy to help out getting things started and > pass on "ownership" of the code. > > Any brave volunteers? Yes, me, absolutely. xoxo, Andy -- Andy Lester => andy@petdance.com => www.petdance.com => AIM:petdance From elfring at users.sourceforge.net Sun Jul 15 10:14:04 2007 From: elfring at users.sourceforge.net (SF Markus Elfring) Date: Sun Jul 15 10:14:17 2007 Subject: [splint-discuss] Moving to Google Code In-Reply-To: <469A4EAF.5010700@cs.virginia.edu> References: <1A3B51A8-AF7D-4D47-B3A8-2097814034C1@petdance.com> <469801B0.2060204@cs.virginia.edu> <469A3F75.8080506@users.sourceforge.net> <0FCA4CEB-A169-407F-9059-29FA501A06F1@petdance.com> <469A4EAF.5010700@cs.virginia.edu> Message-ID: <469A55DC.9020209@users.sourceforge.net> > I believe the only way significant improvements will happen is if > someone volunteers to lead and manage the effort. If someone wants to > do this, I would be happy to help out getting things started and pass > on "ownership" of the code. How are the chances for clean-up between the referenced configurations? https://sourceforge.net/projects/lclint/ https://sourceforge.net/projects/splint/ https://sourceforge.net/projects/splintpp/ Regards, Markus From elfring at users.sourceforge.net Sun Jul 15 11:03:09 2007 From: elfring at users.sourceforge.net (SF Markus Elfring) Date: Sun Jul 15 11:03:20 2007 Subject: [splint-discuss] Moving to a proper issue tracking system In-Reply-To: <0FCA4CEB-A169-407F-9059-29FA501A06F1@petdance.com> References: <1A3B51A8-AF7D-4D47-B3A8-2097814034C1@petdance.com> <469801B0.2060204@cs.virginia.edu> <469A3F75.8080506@users.sourceforge.net> <0FCA4CEB-A169-407F-9059-29FA501A06F1@petdance.com> Message-ID: <469A615D.4020601@users.sourceforge.net> > I would be glad to help out however I can. If the open issues were > moved to the bug tracker in SourceForge, it would make it easier to > see what's what. It would also be far better to can the static page > of "known bugs" and replace it with a searchable database. This is partly available. The document "http://splint.org/bugs.html" refers to the list "http://sourceforge.net/tracker/?group_id=9538&atid=109538" which belongs to the project "Old LCLint Project". I would appreciate if this link will be updated to avoid confusion with the list "http://sourceforge.net/tracker/?atid=459911&group_id=34302&func=browse" which belongs to the project "splint - secure programming lint". There is a bit competition between the communication/collaboration in mailing lists and issue tracking systems. > Better still, if the entire project were moved to Google Code, it > would be a quantum leap forward in usability. You'd get a bug tracker > that's usable, a wiki, and Subversion support instead of clunky old CVS. How do you think about the approach "Importing Data into SVN"? https://sourceforge.net/docman/display_doc.php?docid=31070&group_id=1#import Would you like to consider other source control management systems like Git for distributed work? http://en.wikipedia.org/wiki/Git_%28software%29 Regards, Markus From andy at petdance.com Sun Jul 15 10:03:24 2007 From: andy at petdance.com (Andy Lester) Date: Sun Jul 15 16:44:28 2007 Subject: [splint-discuss] Moving to Google Code In-Reply-To: <469A4EAF.5010700@cs.virginia.edu> References: <1A3B51A8-AF7D-4D47-B3A8-2097814034C1@petdance.com> <469801B0.2060204@cs.virginia.edu> <469A3F75.8080506@users.sourceforge.net> <0FCA4CEB-A169-407F-9059-29FA501A06F1@petdance.com> <469A4EAF.5010700@cs.virginia.edu> Message-ID: On Jul 15, 2007, at 11:43 AM, David Evans wrote: > I believe the only way significant improvements will happen is if > someone volunteers to lead and manage the effort. If someone wants > to do this, I would be happy to help out getting things started and > pass on "ownership" of the code. > > Any brave volunteers? Yes, me, absolutely. xoxo, Andy -- Andy Lester => andy@petdance.com => www.petdance.com => AIM:petdance From asim.zaka at actaris.itron.com Mon Jul 16 02:52:07 2007 From: asim.zaka at actaris.itron.com (Asim Zaka) Date: Mon Jul 16 04:58:15 2007 Subject: [splint-discuss] (no subject) In-Reply-To: References: Message-ID: <7.0.0.16.2.20070716105051.02269dc8@actaris.itron.com> An HTML attachment was scrubbed... URL: http://www.cs.Virginia.EDU/pipermail/splint-discuss/attachments/20070716/e58fb5c0/attachment.html From ajay.goel at bhartitelesoft.com Mon Jul 16 05:12:01 2007 From: ajay.goel at bhartitelesoft.com (Ajay Goel) Date: Mon Jul 16 05:12:55 2007 Subject: [splint-discuss] (no subject) In-Reply-To: <7.0.0.16.2.20070716105051.02269dc8@actaris.itron.com> Message-ID: Hi Asim Pervez Zaka, Run SPLint in strict mode and find which file is missing then include path for that file and run SPLint again. Most of the time Preprocessing Error comes due to some missing file. Regards Ajay Goel Software Engineer Bhartitelesoft India -----Original Message----- From: splint-discuss-bounces@cs.virginia.edu [mailto:splint-discuss-bounces@cs.virginia.edu]On Behalf Of Asim Zaka Sent: Monday, July 16, 2007 3:22 PM To: Discussions about the Splint annotation-assisted static analysis project; Discussions about the Splint annotation-assisted static analysis project Subject: [splint-discuss] (no subject) I am getting the following errors with Splint: In file included from \\fx1112\compilers\h8300\v4_20c\inc\string.h(13), from ./c/magtampermgr.c(26) \\fx1112\compilers\h8300\v4_20c\inc\sysmac.h(52,23): syntax error - missing right operand \\fx1112\compilers\h8300\v4_20c\inc\sysmac.h(60,23): syntax error - missing right operand Preprocessing error for file: ./c/magtampermgr.c *** Cannot continue. *** Error code 1 (ignored) Can anyone please tell me how to get round it? Thanks. Asim Pervez Zaka Firmware Engineer Actaris, Langer Road, Felixstowe, Suffolk, England IP11 2ER -------------- next part -------------- An HTML attachment was scrubbed... URL: http://www.cs.Virginia.EDU/pipermail/splint-discuss/attachments/20070716/999d422a/attachment.html From lionel_debroux at yahoo.fr Mon Jul 16 07:16:12 2007 From: lionel_debroux at yahoo.fr (Lionel_Debroux) Date: Mon Jul 16 07:23:12 2007 Subject: [splint-discuss] Moving to Google Code Message-ID: <469B7DAC.3020608@yahoo.fr> > Would you like to consider other source control management systems > like Git for distributed work? > http://en.wikipedia.org/wiki/Git_%28software%29 Yes, Git is one of the good options for modern distributed SCM. Among the other SCM of that class are Mercurial and SVK. As a recent user of splint, I'd be happy if this powerful and GPLed tool was revived, and new features were added :) I'm not sure this is the best place to make feature requests, but here are two missing features (IMO) anyway: * better support for the ISO C99 portable types defined in stdint.h: (u)int8/16/32/64_t, and their variants. Currently, I use them in a program destined to be cross-platform (well, a standard install of Visual Studio 2005 still doesn't have stdint.h, but one can easily find on the Web multiple stdint.h tailored for Visual Studio), and I get a number of warnings such as the following one: file:line:column: Format argument 1 to fscanf (%u) expects unsigned int * gets uint32_t *: ... file:line:column: Corresponding format code which is a spurious warning on a number of platforms with a 32-bit "int" type, like the IA32 platform : typedef unsigned int uint32_t; * state clauses for global variables, because these are useful to track memory leaks. I guess the former is easier to implement than the latter... I don't rule out any involvment in the project as a programmer, but by all means, I'd rather avoid introducing bugs which would make the code checks incorrect. I'm still a CS student, after all... :D And of course, I can do some beta-test :) Regards, Lionel Debroux. From lionel_debroux at yahoo.fr Mon Jul 16 07:33:23 2007 From: lionel_debroux at yahoo.fr (Lionel_Debroux) Date: Mon Jul 16 07:40:17 2007 Subject: [splint-discuss] Moving to Google Code Message-ID: <469B81B3.3030606@yahoo.fr> > Would you like to consider other source control management systems > like Git for distributed work? > http://en.wikipedia.org/wiki/Git_%28software%29 Yes, Git is one of the good options for modern distributed SCM. Among the other SCM of that class are Mercurial and SVK. As a recent user of splint, I'd be happy if this powerful and GPLed tool was revived, and new features were added :) I'm not sure this is the best place to make feature requests, but here are two missing features (IMO) anyway: * better support for the ISO C99 portable types defined in stdint.h: (u)int8/16/32/64_t, and their variants. Currently, I use them in a program destined to be cross-platform (well, a standard install of Visual Studio 2005 still doesn't have stdint.h, but one can easily find on the Web multiple stdint.h tailored for Visual Studio), and I get a number of warnings such as the following one: file:line:column: Format argument 1 to fscanf (%u) expects unsigned int * gets uint32_t *: ... file:line:column: Corresponding format code which is a spurious warning on a number of platforms with a 32-bit "int" type, like the IA32 platform : typedef unsigned int uint32_t; * state clauses for global variables, because these are useful to track memory leaks. I guess the former is easier to implement than the latter... I don't rule out any involvment in the project as a programmer, but by all means, I'd rather avoid introducing bugs which would make the code checks incorrect. I'm still a CS student, after all... :D And of course, I can do some beta-test :) Regards, Lionel Debroux. From asim.zaka at actaris.itron.com Mon Jul 16 08:32:59 2007 From: asim.zaka at actaris.itron.com (Asim Zaka) Date: Mon Jul 16 08:33:13 2007 Subject: [splint-discuss] SPLINT sysmac.h error In-Reply-To: <469B81B3.3030606@yahoo.fr> References: <469B81B3.3030606@yahoo.fr> Message-ID: <7.0.0.16.2.20070716162904.022a1b78@actaris.itron.com> An HTML attachment was scrubbed... URL: http://www.cs.Virginia.EDU/pipermail/splint-discuss/attachments/20070716/b7856b25/attachment.html From asim.zaka at actaris.itron.com Mon Jul 16 08:35:51 2007 From: asim.zaka at actaris.itron.com (Asim Zaka) Date: Mon Jul 16 08:36:02 2007 Subject: [splint-discuss] (no subject) In-Reply-To: References: <7.0.0.16.2.20070716105051.02269dc8@actaris.itron.com> Message-ID: <7.0.0.16.2.20070716163432.0229e6b8@actaris.itron.com> An HTML attachment was scrubbed... URL: http://www.cs.Virginia.EDU/pipermail/splint-discuss/attachments/20070716/fcfe3026/attachment.html From asim.zaka at actaris.itron.com Mon Jul 16 08:32:59 2007 From: asim.zaka at actaris.itron.com (Asim Zaka) Date: Mon Jul 16 09:17:53 2007 Subject: [splint-discuss] SPLINT sysmac.h error In-Reply-To: <469B81B3.3030606@yahoo.fr> References: <469B81B3.3030606@yahoo.fr> Message-ID: <7.0.0.16.2.20070716162904.022a1b78@actaris.itron.com> An HTML attachment was scrubbed... URL: http://www.cs.Virginia.EDU/pipermail/splint-discuss/attachments/20070716/b7856b25/attachment-0003.html From lholzheid at bihl-wiedemann.de Mon Jul 16 10:34:31 2007 From: lholzheid at bihl-wiedemann.de (Ludolf Holzheid) Date: Mon Jul 16 10:35:08 2007 Subject: [splint-discuss] SPLINT sysmac.h error In-Reply-To: <7.0.0.16.2.20070716162904.022a1b78@actaris.itron.com> References: <469B81B3.3030606@yahoo.fr> <7.0.0.16.2.20070716162904.022a1b78@actaris.itron.com> Message-ID: <20070716173431.GA24629@svr5.bihl-wiedemann.de> On Mon, 2007-07-16 16:32:59 +0100, Asim Zaka wrote: > > > Hi All,

> I am putting my C code through SPlint for refining it using IAR C > compiler for H8 microprocessors. I get the following errors:

> splint.exe -preproc -linelen 600 > -DH8_38327 -DCLOCK_16MHZ -D_ISSUE -I./h/ -I\inc  > [..] > Splint 3.0.1.6 --- 11 Feb 2002

>    In file included from > \\fx1112\compilers\h8300\v4_20c\inc\string.h(13),
>                  > from ./c/magtampermgr.c(26)
> \\fx1112\compilers\h8300\v4_20c\inc\sysmac.h(52,23): syntax error - > missing right operand
Hi Asim, you'll never get the IAR headers parsed by an ISO/ANSI-C parser. It will choke at least at the sfrb and sfrw statements. For an H8 project I used splint with, I wrote my own versions of the offending headers and put them in a separate directory. I've put this directory on the top of the list of include directories for splint (i.e. first -I flag) in order to have them parsed instead of the IAR ones. Of course, the compiler still used the original headers. HTH, Ludolf -- --------------------------------------------------------------- Ludolf Holzheid Tel: +49 621 339960 Bihl+Wiedemann GmbH Fax: +49 621 3392239 Flo?w?rthstra?e 41 e-mail: lholzheid@bihl-wiedemann.de D-68199 Mannheim, Germany --------------------------------------------------------------- From brian.quinlan at iolfree.ie Mon Jul 16 12:46:46 2007 From: brian.quinlan at iolfree.ie (Brian Quinlan) Date: Mon Jul 16 11:54:27 2007 Subject: [splint-discuss] SPLINT sysmac.h error In-Reply-To: <20070716173431.GA24629@svr5.bihl-wiedemann.de> References: <469B81B3.3030606@yahoo.fr> <7.0.0.16.2.20070716162904.022a1b78@actaris.itron.com> <20070716173431.GA24629@svr5.bihl-wiedemann.de> Message-ID: <1184615206.5538.13.camel@akebono> On Mon, 2007-07-16 at 19:34 +0200, Ludolf Holzheid wrote: > On Mon, 2007-07-16 16:32:59 +0100, Asim Zaka wrote: > > > > > > Hi All,

> > I am putting my C code through SPlint for refining it using IAR C > > compiler for H8 microprocessors. I get the following errors:

> > splint.exe -preproc -linelen 600 > > -DH8_38327 -DCLOCK_16MHZ -D_ISSUE -I./h/ -I\inc  > > [..] > > Splint 3.0.1.6 --- 11 Feb 2002

> >    In file included from > > \\fx1112\compilers\h8300\v4_20c\inc\string.h(13),
> >                  > > from ./c/magtampermgr.c(26)
> > \\fx1112\compilers\h8300\v4_20c\inc\sysmac.h(52,23): syntax error - > > missing right operand
> > Hi Asim, > > you'll never get the IAR headers parsed by an ISO/ANSI-C parser. It > will choke at least at the sfrb and sfrw statements. > > For an H8 project I used splint with, I wrote my own versions of the > offending headers and put them in a separate directory. I've put this > directory on the top of the list of include directories for splint > (i.e. first -I flag) in order to have them parsed instead of the IAR > ones. > > Of course, the compiler still used the original headers. > > HTH, > > Ludolf > Hi Asim & Ludolf, If sfrb, sfrw or indeed anything else non-standard is causing parse problems for splint, you may find that you can usefully redefine them via the splint -D command-line option. A few examples: -Dsfrb="" will tell splint's preprocessor to define sfrb to be the empty string. -Dsfrb="unsigned char" will tell splint to treat sfrb as an unsigned character. -Dsfrb'('w,x,y,z')'="" might be more appropriate if sfrb takes arguments I'm not familiar with the IAR compiler, so I don't know if sfrb & sfrw can safely be ignored by splint, or whether redefining them will "fool" splint appropriately. Bye, Brian From lholzheid at bihl-wiedemann.de Mon Jul 16 12:57:40 2007 From: lholzheid at bihl-wiedemann.de (Ludolf Holzheid) Date: Mon Jul 16 12:57:50 2007 Subject: [splint-discuss] SPLINT sysmac.h error In-Reply-To: <1184615206.5538.13.camel@akebono> References: <469B81B3.3030606@yahoo.fr> <7.0.0.16.2.20070716162904.022a1b78@actaris.itron.com> <20070716173431.GA24629@svr5.bihl-wiedemann.de> <1184615206.5538.13.camel@akebono> Message-ID: <20070716195740.GA3473@svr5.bihl-wiedemann.de> On Mon, 2007-07-16 20:46:46 +0100, Brian Quinlan wrote: > [..] > Hi Asim & Ludolf, > If sfrb, sfrw or indeed anything else non-standard is causing parse > problems for splint, you may find that you can usefully redefine them > via the splint -D command-line option. Hi Brian, this was my first idea too, but unfortunately IAR declares 'special function registers' for microcontrollers with a totally non-standard syntax like that: #define WDTCTL_ (0x0120) /* Watchdog Timer Control */ sfrw WDTCTL = WDTCTL_; This means "using the symbol WDTCTL, you will access, the 16-bit wide 'watchdog timer control' register at address 0x0120". A clean ISO/ANSI-C code replacement to be presented to splint would be e.g.: #if !defined MAIN_MODULE extern #endif unsigned short WDCTL; Moreover, if you check IAR code with splint, you'll need a header with the declaration of the 'intrinsic functions' (EINT(), NOP(), etc.) anyway. Ludolf -- --------------------------------------------------------------- Ludolf Holzheid Tel: +49 621 339960 Bihl+Wiedemann GmbH Fax: +49 621 3392239 Flo?w?rthstra?e 41 e-mail: lholzheid@bihl-wiedemann.de D-68199 Mannheim, Germany --------------------------------------------------------------- From ok at cs.otago.ac.nz Mon Jul 16 16:22:07 2007 From: ok at cs.otago.ac.nz (ok) Date: Mon Jul 16 16:31:17 2007 Subject: [splint-discuss] SPLINT sysmac.h error In-Reply-To: <7.0.0.16.2.20070716162904.022a1b78@actaris.itron.com> References: <469B81B3.3030606@yahoo.fr> <7.0.0.16.2.20070716162904.022a1b78@actaris.itron.com> Message-ID: Show us the actual code that splint is complaining about (that is, the lines in sysmac.h). From lholzheid at bihl-wiedemann.de Mon Jul 16 17:03:13 2007 From: lholzheid at bihl-wiedemann.de (Ludolf Holzheid) Date: Mon Jul 16 17:03:26 2007 Subject: [splint-discuss] SPLINT sysmac.h error In-Reply-To: References: <469B81B3.3030606@yahoo.fr> <7.0.0.16.2.20070716162904.022a1b78@actaris.itron.com> Message-ID: <20070717000313.GA5933@svr5.bihl-wiedemann.de> On Tue, 2007-07-17 11:22:07 +1200, ok wrote: > Show us the actual code that splint is complaining about > (that is, the lines in sysmac.h). Assuming Asim has the same version of IAR's sysmac.h, both offending lines are > #if sizeof((char*)0 - (char*)0) <= sizeof(int) Even if there was a 'sizeof' operator added to the preprocessor, this will never give meaningful results for any ISO-C compatible preprocessor, as the standard says, for preprocessor tokens, all integer types act as if they were intmax_t or uintmax_t, respectively. Anyway, due to other non-standard extensions of the IAR compiler, I'm afraid Asim has to write replacements for the IAR headers anyway (which could be minimalist and just enough to get splint running, as he wants to check his own code only). Ludolf -- --------------------------------------------------------------- Ludolf Holzheid Tel: +49 621 339960 Bihl+Wiedemann GmbH Fax: +49 621 3392239 Flo?w?rthstra?e 41 e-mail: lholzheid@bihl-wiedemann.de D-68199 Mannheim, Germany --------------------------------------------------------------- From asim.zaka at actaris.itron.com Tue Jul 17 01:42:48 2007 From: asim.zaka at actaris.itron.com (Asim Zaka) Date: Tue Jul 17 01:43:00 2007 Subject: [splint-discuss] SPLINT sysmac.h error In-Reply-To: <1184615206.5538.13.camel@akebono> References: <469B81B3.3030606@yahoo.fr> <7.0.0.16.2.20070716162904.022a1b78@actaris.itron.com> <20070716173431.GA24629@svr5.bihl-wiedemann.de> <1184615206.5538.13.camel@akebono> Message-ID: <7.0.0.16.2.20070717093522.02230a58@actaris.itron.com> An HTML attachment was scrubbed... URL: http://www.cs.Virginia.EDU/pipermail/splint-discuss/attachments/20070717/725f1ac8/attachment.html From lholzheid at bihl-wiedemann.de Tue Jul 17 06:55:14 2007 From: lholzheid at bihl-wiedemann.de (Ludolf Holzheid) Date: Tue Jul 17 06:55:32 2007 Subject: [splint-discuss] SPLINT sysmac.h error In-Reply-To: <7.0.0.16.2.20070717084250.02230bd0@actaris.itron.com> <7.0.0.16.2.20070717093522.02230a58@actaris.itron.com> References: <469B81B3.3030606@yahoo.fr> <7.0.0.16.2.20070716162904.022a1b78@actaris.itron.com> <20070716173431.GA24629@svr5.bihl-wiedemann.de> <7.0.0.16.2.20070717084250.02230bd0@actaris.itron.com> <469B81B3.3030606@yahoo.fr> <7.0.0.16.2.20070716162904.022a1b78@actaris.itron.com> <20070716173431.GA24629@svr5.bihl-wiedemann.de> <1184615206.5538.13.camel@akebono> <7.0.0.16.2.20070717093522.02230a58@actaris.itron.com> Message-ID: <20070717135514.GA13214@svr5.bihl-wiedemann.de> On Tue, 2007-07-17 09:42:48 +0100, Asim Zaka wrote: > [..] >
Maybe you would like to add support in lint for IAR compiler for > code which uses string.h.

As I wrote in the other mail, adding a 'sizeof' operator to an ISO/ANSI compatible preprocessor doesn't make any sense, as it would have to return the same value for all integer types. I don't think anyone would like to add support for that non-standard compiler extension which would work as expected for the H8 IAR compiler only. On Tue, 2007-07-17 08:44:34 +0100, Asim Zaka wrote: > > > Hi,

> Would it be possible for you to send these headers to me?

> So there is no splint switch or setting or way around it as long as my C > source includes the string.h file.

The changed headers are part of a work for a customer, so I don't own the copyright and cannot disclose it, sorry. Moreover, it has been a safety-related project, so I had to avoid library routines as far as possible. I did not use headers including sysmac.h and did not adapt it. But it is easy to do it yourself: o Make a copy of the IAR 'inc' directory (e.g. to 'splint-inc' in the project source directory) o remove or comment-out the offending lines (see the patch attached) o in splint's include search path, replace the IAR directory with the new one Another possibility to get rid of _this_ error is to add the IAR directory to the include search path (-I flag) and to the list of system directories (-sysdirs flag) and specifying '-sysdirerrors' (and an appropriate library such as +ansilib). This may help for the standard headers, but will not help for the sfrb/sfrw declarations. Ludolf P.S.: I would really appreciate if you could figure out how to configure your Eudora to send plain text mails. -- --------------------------------------------------------------- Ludolf Holzheid Tel: +49 621 339960 Bihl+Wiedemann GmbH Fax: +49 621 3392239 Flo?w?rthstra?e 41 e-mail: lholzheid@bihl-wiedemann.de D-68199 Mannheim, Germany --------------------------------------------------------------- -------------- next part -------------- --- inc\sysmac.h Thu Feb 28 11:36:36 2002 +++ splint-inc\sysmac.h Tue Jul 17 14:59:03 2007 @@ -49,19 +49,19 @@ #endif #ifndef __SIZE_T_TYPE__ -#if sizeof((char*)0 - (char*)0) <= sizeof(int) +/*#if sizeof((char*)0 - (char*)0) <= sizeof(int)*/ #define __SIZE_T_TYPE__ unsigned int -#else -#define __SIZE_T_TYPE__ unsigned long -#endif +/*#else*/ +/*#define __SIZE_T_TYPE__ unsigned long */ +/*#endif*/ #endif #ifndef __PTRDIFF_T_TYPE__ -#if sizeof((char*)0 - (char*)0) <= sizeof(int) +/*#if sizeof((char*)0 - (char*)0) <= sizeof(int)*/ #define __PTRDIFF_T_TYPE__ unsigned int -#else -#define __PTRDIFF_T_TYPE__ unsigned long -#endif +/*#else*/ +/*#define __PTRDIFF_T_TYPE__ unsigned long */ +/*#endif*/ #endif #ifndef __JMP_BUF_ELEMENT_TYPE__ From wenzel at bbr-vt.de Thu Jul 19 01:58:58 2007 From: wenzel at bbr-vt.de (Wenzel, Bodo) Date: Thu, 19 Jul 2007 07:58:58 +0200 Subject: [splint-discuss] Suggestion for SFR (not only for IAR) Message-ID: <469F19C3.2547.139DCA@wenzel.bbr-vt.de> Hi. It's not only the IAR compiler with this syntax for defining SFR (special function registers), there are Keil and SDCC, too, just to mention two I know of. My suggestion is to define macros like #define SFR_BYTE(name, address) ... #define SFR_WORD(name, address) ... in a compiler specific header file that expand to the needed syntax. For Splint you might use another syntax which defines the SFRs as simple static variables of the appropriate type. The macro S_SPLINT_S can be used to distinguish between "Splint time" and "compilation time". HTH, Bodo Mit freundlichen Gr??en, Bodo Wenzel - Entwicklung Software - -- BBR - Baudis Bergmann R?sch Verkehrstechnik GmbH Pillaustra?e 1e D - 38126 Braunschweig T: +49.531.27300-766 F: +49.531.27300-999 @: wenzel at bbr-vt.de W: http://www.bbr-vt.de Registergericht: AG Braunschweig HRB 3037 Gesch?ftsf?hrer: Dipl.-Ing. Arne Baudis Dipl.-Ing. Thomas Bergmann Dipl.-Ing. Frank-Michael R?sch USt.-ID-Nr.: DE 114 877 881