<html>
    <head>
      <base href="https://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 --- - clang-format will produce temporary file on Windows 10"
   href="https://llvm.org/bugs/show_bug.cgi?id=26286">26286</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>clang-format will produce temporary file on Windows 10
          </td>
        </tr>

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

        <tr>
          <th>Version</th>
          <td>3.8
          </td>
        </tr>

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

        <tr>
          <th>OS</th>
          <td>other
          </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>Formatter
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedclangbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>nayuhz@gmail.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>djasper@google.com, klimek@google.com, llvm-bugs@lists.llvm.org
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Created <span class=""><a href="attachment.cgi?id=15702" name="attach_15702" title="the .clang-format  which can reproduce the bug.">attachment 15702</a> <a href="attachment.cgi?id=15702&action=edit" title="the .clang-format  which can reproduce the bug.">[details]</a></span>
the .clang-format  which can reproduce the bug.

I'am working on Windows 10 x64, and run clang-format 3.8 in cmd.
But I found that clang-format will produce a temporary file when I run:
clang-format.exe -i -style=file file_to_format.c

like <a class="bz_bug_link 
          bz_status_NEW "
   title="NEW --- - Clang format creates unwanted temporary files when batching processing on windows"
   href="show_bug.cgi?id=26125">Bug 26125</a>, is clang-format not exiting correctly?
but the code have been formatted correctly.

It could be reproduced every times.

On linux, I use clang-format 3.4.2 to do this, but, segmentation fault, as
follow:
Can't find usable .clang-format, using LLVM style
0  libLLVM-3.4.so  0x00007f7d1f28d612 llvm::sys::PrintStackTrace(_IO_FILE*) +
50
1  libLLVM-3.4.so  0x00007f7d1f28d3d4
2  libpthread.so.0 0x00007f7d1df5b130
3  clang-format    0x0000000000bed8a4
4  clang-format    0x0000000000be6d6c
5  clang-format    0x0000000000a30cd7
6  clang-format    0x000000000045da12
7  clang-format    0x000000000045ba54
8  libc.so.6       0x00007f7d1cd57af5 __libc_start_main + 245
9  clang-format    0x000000000045c811
Segmentation fault (core dumped)

The windows version of clang is :
clang version 3.8.0 (trunk)
Target: i686-pc-windows-msvc
Thread model: posix


The attachment is the .clang-format which can reproduce the bug.</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>