<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
Hi, maybe you already checked this, but if you have any big wheels
like a QFileDialog declared static, their ctors most likely will run
before main(), i.e. some COM/networking activity could occur before
main() kicks in.<br>
<br>
<div class="moz-cite-prefix">On 2020-02-05 21:10, maitai wrote:<br>
</div>
<blockquote type="cite"
cite="mid:a0186123d960a766562b6bef7c2dcd23@virtual-winds.org">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<p>As I said, I now have doubts it comes from COM threading...</p>
<p>I have built a small app with nothing inside, with the same
.pro file exactly (qt modules, libs, etc, in the same order).
The only difference is HEADERS and SOURCES of course, main.cpp
being the same at least until it crashes. No problem in this
small app (running in the same directory).</p>
<p>Again for those who missed it:</p>
<p>main.cpp:</p>
<pre><span> </span><span>QNetworkAccessManager</span><span> </span>*<span>inet</span><span> </span>=<span> </span><span>new</span><span> </span><span>QNetworkAccessManager</span>();</pre>
<pre><span> </span><span>delete</span><span> </span><span>inet</span>;</pre>
<pre><span> </span><span>QApplication</span><span> </span><span>app</span>(<span>argc</span>,<span> </span><span>argv</span>);</pre>
<pre>this works.</pre>
<pre><span> </span><span>QApplication</span><span> </span><span>app</span>(<span>argc</span>,<span> </span><span>argv</span>);</pre>
<pre> <span></span><span>QNetworkAccessManager</span><span> </span>*<span>inet</span><span> </span>=<span> </span><span>new</span><span> </span><span>QNetworkAccessManager</span>();</pre>
<pre><span> </span><span>delete</span><span> </span><span>inet</span>;</pre>
<pre><span></span>this crashes on new in our app, not in a sample without HEADERS and SOURCES.
I cannot understand that, certainly there is something obvious I am missing.
Philippe Lelong.
</pre>
</blockquote>
</body>
</html>