]>
Commit | Line | Data |
---|---|---|
885824d3 | 1 | |
f9264521 | 2 | employee.c: (in function employee_sprint) |
3 | employee.c:38: Buffer overflow possible with sprintf. Recommend using snprintf | |
4 | instead: sprintf | |
5 | drive.c: (in function main) | |
6 | drive.c:50: Buffer overflow possible with sprintf. Recommend using snprintf | |
7 | instead: sprintf | |
8 | drive.c:66: Buffer overflow possible with sprintf. Recommend using snprintf | |
9 | instead: sprintf | |
10 | drive.c:84: Buffer overflow possible with sprintf. Recommend using snprintf | |
11 | instead: sprintf | |
12 | drive.c:138: Buffer overflow possible with sprintf. Recommend using snprintf | |
13 | instead: sprintf | |
885824d3 | 14 | |
15 | Error Type Reported Suppressed | |
16 | =================== ======== ========= | |
17 | usedef 0 1 | |
3120b462 | 18 | compdef 0 3 |
bb7c2085 | 19 | incondefs 0 1 |
3120b462 | 20 | formalarray 0 24 |
bb7c2085 | 21 | modfilesys 0 25 |
22 | redecl 0 7 | |
23 | exporttype 0 3 | |
f9264521 | 24 | bufferoverflowhigh 5 0 |
885824d3 | 25 | ======== ========= |
f9264521 | 26 | Total 5 64 |
885824d3 | 27 | |
f9264521 | 28 | Finished checking --- 5 code warnings, as expected |
885824d3 | 29 | |
f9264521 | 30 | employee.c: (in function employee_sprint) |
31 | employee.c:38: Buffer overflow possible with sprintf. Recommend using snprintf | |
32 | instead: sprintf | |
885824d3 | 33 | eref.c: (in function eref_alloc) |
34 | eref.c:36: Called procedure printf may access global stdout | |
35 | eref.c:36: Undocumented modification of *stdout possible from call to printf: | |
36 | printf("Malloc returned null in eref_alloc\n") | |
37 | eref.c:36: Return value (type int) ignored: printf("Malloc r... | |
38 | eref.c:46: Called procedure printf may access global stdout | |
39 | eref.c:46: Undocumented modification of *stdout possible from call to printf: | |
40 | printf("Malloc returned null in eref_alloc\n") | |
41 | eref.c:46: Return value (type int) ignored: printf("Malloc r... | |
42 | eref.c: (in function eref_initMod) | |
43 | eref.c:82: Called procedure printf may access global stdout | |
44 | eref.c:82: Undocumented modification of *stdout possible from call to printf: | |
45 | printf("Malloc returned null in eref_initMod\n") | |
46 | eref.c:82: Return value (type int) ignored: printf("Malloc r... | |
47 | eref.c:90: Called procedure printf may access global stdout | |
48 | eref.c:90: Undocumented modification of *stdout possible from call to printf: | |
49 | printf("Malloc returned null in eref_initMod\n") | |
50 | eref.c:90: Return value (type int) ignored: printf("Malloc r... | |
51 | erc.c: (in function int_toSize) | |
52 | erc.c:11: Undocumented use of global stderr | |
53 | erc.c:11: Undocumented modification of *stderr possible from call to fprintf: | |
54 | fprintf(stderr, "Error: int_toSize failure: %d", x) | |
55 | erc.c:11: Return value (type int) ignored: fprintf(stderr, ... | |
56 | erc.c: (in function erc_create) | |
57 | erc.c:28: Called procedure printf may access global stdout | |
58 | erc.c:28: Undocumented modification of *stdout possible from call to printf: | |
59 | printf("Malloc returned null in erc_create\n") | |
60 | erc.c:28: Return value (type int) ignored: printf("Malloc r... | |
61 | erc.c: (in function erc_insert) | |
62 | erc.c:80: Called procedure printf may access global stdout | |
63 | erc.c:80: Undocumented modification of *stdout possible from call to printf: | |
64 | printf("Malloc returned null in erc_insert\n") | |
65 | erc.c:80: Return value (type int) ignored: printf("Malloc r... | |
66 | erc.c: (in function erc_sprint) | |
67 | erc.c:145: Called procedure printf may access global stdout | |
68 | erc.c:145: Undocumented modification of *stdout possible from call to printf: | |
69 | printf("Malloc returned null in erc_sprint\n") | |
70 | erc.c:145: Return value (type int) ignored: printf("Malloc r... | |
71 | dbase.c: (in function db_print) | |
72 | dbase.c:307: Return value (type int) ignored: printf("Employee... | |
73 | dbase.c:312: Return value (type int) ignored: printf("%s", pri... | |
74 | drive.c: (in function main) | |
75 | drive.c:31: Called procedure printf may access global stdout | |
76 | drive.c:31: Undocumented modification of *stdout possible from call to printf: | |
77 | printf("FormatPos: Wrong number of arguments. Given %d needs 0.\n", argc - | |
78 | 1) | |
79 | drive.c:31: Return value (type int) ignored: printf("FormatPo... | |
80 | drive.c:41: Called procedure printf may access global stdout | |
81 | drive.c:41: Undocumented modification of *stdout possible from call to printf: | |
82 | printf("Size should be 0.\n") | |
83 | drive.c:41: Return value (type int) ignored: printf("Size sho... | |
f9264521 | 84 | drive.c:50: Buffer overflow possible with sprintf. Recommend using snprintf |
85 | instead: sprintf | |
885824d3 | 86 | drive.c:57: Called procedure printf may access global stdout |
87 | drive.c:57: Undocumented modification of *stdout possible from call to printf: | |
88 | printf("Size should be 500.\n") | |
89 | drive.c:57: Return value (type int) ignored: printf("Size sho... | |
f9264521 | 90 | drive.c:66: Buffer overflow possible with sprintf. Recommend using snprintf |
91 | instead: sprintf | |
885824d3 | 92 | drive.c:73: Called procedure printf may access global stdout |
93 | drive.c:73: Undocumented modification of *stdout possible from call to printf: | |
94 | printf("Size should be 250.\n") | |
95 | drive.c:73: Return value (type int) ignored: printf("Size sho... | |
f9264521 | 96 | drive.c:84: Buffer overflow possible with sprintf. Recommend using snprintf |
97 | instead: sprintf | |
885824d3 | 98 | drive.c:93: Called procedure printf may access global stdout |
99 | drive.c:93: Undocumented modification of *stdout possible from call to printf: | |
100 | printf("Size should be 350.\n") | |
101 | drive.c:93: Return value (type int) ignored: printf("Size sho... | |
102 | drive.c:100: Called procedure printf may access global stdout | |
103 | drive.c:100: Undocumented modification of *stdout possible from call to printf: | |
104 | printf("Size should be 350.\n") | |
105 | drive.c:100: Return value (type int) ignored: printf("Size sho... | |
106 | drive.c:103: Called procedure printf may access global stdout | |
107 | drive.c:103: Undocumented modification of *stdout possible from call to printf: | |
108 | printf("Print two different employees:\n") | |
109 | drive.c:103: Return value (type int) ignored: printf("Print tw... | |
110 | drive.c:109: Called procedure printf may access global stdout | |
111 | drive.c:109: Undocumented modification of *stdout possible from call to printf: | |
112 | printf("%s\n", &(na[0])) | |
113 | drive.c:109: Return value (type int) ignored: printf("%s\n", &... | |
f9264521 | 114 | drive.c:138: Buffer overflow possible with sprintf. Recommend using snprintf |
115 | instead: sprintf | |
885824d3 | 116 | drive.c:151: Called procedure printf may access global stdout |
117 | drive.c:151: Undocumented modification of *stdout possible from call to printf: | |
118 | printf("Should print true: %s\n", bool_unparse(status == DBS_DUPLERR)) | |
119 | drive.c:151: Return value (type int) ignored: printf("Should p... | |
120 | drive.c:154: Called procedure printf may access global stdout | |
121 | drive.c:154: Undocumented modification of *stdout possible from call to printf: | |
122 | printf("Employees 0 - 19\n") | |
123 | drive.c:154: Return value (type int) ignored: printf("Employee... | |
124 | drive.c:155: Called procedure db_print may access global stdout | |
125 | drive.c:155: Undocumented modification of *stdout possible from call to | |
126 | db_print: db_print() | |
127 | drive.c:158: Called procedure printf may access global stdout | |
128 | drive.c:158: Undocumented modification of *stdout possible from call to printf: | |
129 | printf("Employees 0 - 16, 18 - 19\n") | |
130 | drive.c:158: Return value (type int) ignored: printf("Employee... | |
131 | drive.c:159: Called procedure db_print may access global stdout | |
132 | drive.c:159: Undocumented modification of *stdout possible from call to | |
133 | db_print: db_print() | |
134 | drive.c:164: Called procedure printf may access global stdout | |
135 | drive.c:164: Undocumented modification of *stdout possible from call to printf: | |
136 | printf("Should get two females: %d\n%s\n", i, sprintResult) | |
137 | drive.c:164: Return value (type int) ignored: printf("Should g... | |
138 | drive.c:174: Called procedure printf may access global stdout | |
139 | drive.c:174: Undocumented modification of *stdout possible from call to printf: | |
140 | printf("Should get two females and ten males: %d\n%s\n", i, sprintResult) | |
141 | drive.c:174: Return value (type int) ignored: printf("Should g... | |
142 | drive.c:180: Called procedure printf may access global stdout | |
143 | drive.c:180: Undocumented modification of *stdout possible from call to printf: | |
144 | printf("Should get two females: %d\n%s\n", i, sprintResult) | |
145 | drive.c:180: Return value (type int) ignored: printf("Should g... | |
146 | drive.c:184: Called procedure printf may access global stdout | |
147 | drive.c:184: Undocumented modification of *stdout possible from call to printf: | |
148 | printf("Should get 18 employees\n") | |
149 | drive.c:184: Return value (type int) ignored: printf("Should g... | |
150 | drive.c:185: Called procedure db_print may access global stdout | |
151 | drive.c:185: Undocumented modification of *stdout possible from call to | |
152 | db_print: db_print() | |
153 | ||
154 | Error Type Reported Suppressed | |
155 | =================== ======== ========= | |
156 | usedef 0 1 | |
3120b462 | 157 | compdef 0 3 |
bb7c2085 | 158 | incondefs 0 1 |
159 | formalarray 0 24 | |
885824d3 | 160 | mods 26 0 |
161 | modfilesys 0 25 | |
bb7c2085 | 162 | globs 26 0 |
163 | retvalint 25 0 | |
164 | redecl 0 7 | |
165 | exporttype 0 3 | |
f9264521 | 166 | bufferoverflowhigh 5 0 |
885824d3 | 167 | ======== ========= |
f9264521 | 168 | Total 82 64 |
885824d3 | 169 | |
f9264521 | 170 | Finished checking --- 82 code warnings, as expected |