<html>
<head>
<base href="http://llvm.org/bugs/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW --- - false positive when scanning"
href="http://llvm.org/bugs/show_bug.cgi?id=17404">17404</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>false positive when scanning
</td>
</tr>
<tr>
<th>Product</th>
<td>clang
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>URL</th>
<td>http://devel.recluse.de/~bzed/scan-build/citadel/2013-09-29-1/report-v4xZnV.html#Path38
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>Static Analyzer
</td>
</tr>
<tr>
<th>Assignee</th>
<td>kremenek@apple.com
</td>
</tr>
<tr>
<th>Reporter</th>
<td>dothebart@citadel.org
</td>
</tr>
<tr>
<th>CC</th>
<td>llvmbugs@cs.uiuc.edu
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=11295" name="attach_11295" title="Source file producing the false positive">attachment 11295</a> <a href="attachment.cgi?id=11295&action=edit" title="Source file producing the false positive">[details]</a></span>
Source file producing the false positive
This assumes a value to state being one of the both:
789 else if (state == XDG_MIME_MAGIC_EOF || state == XDG_MIME_MAGIC_ERROR)
(29) Taking true branch -> state needs to be XDG_MIME_MAGIC_ERROR
790 _xdg_mime_magic_match_free (match);
so in the next loop it will go here:
case XDG_MIME_MAGIC_ERROR:
793 state = _xdg_mime_magic_parse_error (magic_file);
which may return either XDG_MIME_MAGIC_EOF or XDG_MIME_MAGIC_SECTION; the later
is needed so the loop may continue.
but:
773 switch (state)
42 Control jumps to 'case XDG_MIME_MAGIC_MAGIC:' at line 781
assumes XDG_MIME_MAGIC_MAGIC, which will never happen under this condition.
the file libcitadel /lib /xdgmime /xdgmimemagic.c is availabe here:
<a href="http://code.citadel.org/?p=citadel.git;a=tree;f=libcitadel/lib/xdgmime;h=0c63b6ff7c9c1581fc6e2ae52c3f0b34d82a7149;hb=HEAD">http://code.citadel.org/?p=citadel.git;a=tree;f=libcitadel/lib/xdgmime;h=0c63b6ff7c9c1581fc6e2ae52c3f0b34d82a7149;hb=HEAD</a>
or with the complete library and compile infrastructure here:
<a href="http://easyinstall.citadel.org/libcitadel-8.20.tar.gz">http://easyinstall.citadel.org/libcitadel-8.20.tar.gz</a></pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>