<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 --- - Regression: clang analyzer prefixes /tmp/ to output file"
   href="http://llvm.org/bugs/show_bug.cgi?id=16547">16547</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Regression: clang analyzer prefixes /tmp/ to output file
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>clang
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>trunk
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>All
          </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>pelle@morth.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>Steps to reproduce (on linux):
:; cat > bad.c <<EOT

#include <stdlib.h>

int
warning(void) {
    char *x;

    free(x);
}
EOT
:; strace -f clang --analyze -Xanalyzer -analyzer-output=html bad.c -o
bad.analyse |& grep html

Expected result (cleaned, from clang-3.2):
[pid  7019] mkdir("bad.analyse", 0770)  = 0
[pid  7019] open("bad.analyse/report-5CmV5o", O_RDWR|O_CREAT|O_EXCL, 0600) = 3
[pid  7019] rename("bad.analyse/report-5CmV5o",
"bad.analyse/report-5CmV5o.html") = 0
[pid  7019] open("bad.analyse/report-5CmV5o.html", O_WRONLY|O_CREAT|O_TRUNC,
0664) = 3

Actual result:
[pid 21986] mkdir("bad.analyse", 0770)  = 0
[pid 21986] open("/tmp/bad.analyse/report-35e1c7.html", O_RDWR|O_CREAT|O_EXCL,
0600) = -1 ENOENT (No such file or directory)

Notes:
Regression since 3.2.
I tried bisecting but it turned out to be too difficult to find revisions that
actually compiled. Maybe I didn't have decency tracking setup right...</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>