title: Qt - setText() crahses program
body: <p>I'm trying to get some text input for the user for further use. For this, I used a QInputDialog:</p>
  
  <pre><code>bool ok;
  QString text = QInputDialog::getText(this, tr("QInputDialog::getText()"),
                                       tr("Your input:"), QLineEdit::Normal,
                                       QDir::home().dirName(), &amp;ok);
  if (ok &amp;&amp; !text.isEmpty()) {
      textLabel-&gt;setText(text);
  }
  </code></pre>
  
  <p>This crahses my program at the line <code>textLabel-&gt;setText(text);</code>. If I comment it out, it does not crash, but the <code>text</code> variable stays empty. What am I missing?
  Thank you!</p>