<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    Hi, <br>
    <br>
    Le 13/09/2015 10:44, RISHABH GUPTA a écrit :<br>
    <blockquote
cite="mid:CAB9YDnW68=-yrxYOgaHioYMTXbVtj-SU8vt25BK9ocUP_JQObQ@mail.gmail.com"
      type="cite">
      <div dir="ltr">     Changes<br>
        <div class="gmail_extra">
          <div class="gmail_quote">
            <blockquote class="gmail_quote" style="margin:0px 0px 0px
              0.8ex;border-left:1px solid
              rgb(204,204,204);padding-left:1ex">
              -------<br>
              <br>
              Work more, and reduce segfaults<br>
              <br>
              <br>
              Repository: amarok<br>
              <br>
              <br>
              Description (updated)<br>
              -------<br>
              Port of main.cpp and App<br>
            </blockquote>
            <blockquote class="gmail_quote" style="margin:0px 0px 0px
              0.8ex;border-left:1px solid
              rgb(204,204,204);padding-left:1ex">
              <br>
              It compiles 100%, and there is a segmentation fault after
              the end of the App::continueInit().<br>
              I'm not able to trace it further.<br>
              <br>
              Please help me to port well the main + App class so that
              the play, pause (and so one) commands are well read and to
              deal correctly with the unique/multiple instance.<br>
              <br>
              <br>
              Diffs (updated)<br>
              -----<br>
              <br>
                src/App.h 2089981<br>
                src/scripting/scriptmanager/ScriptManager.cpp bb62be1<br>
                src/scanner/AbstractDirectoryWatcher.cpp 168c68a<br>
                src/org.kde.amarok.desktop PRE-CREATION<br>
                src/main.cpp 385e047<br>
                src/core/support/Components.cpp 9f97eb6<br>
                src/configdialog/dialogs/ScriptsConfig.cpp bbec667<br>
                src/amarok.desktop 433c757<br>
                src/browsers/filebrowser/FileBrowser.cpp 3d40d9b<br>
                src/TrayIcon.cpp be25497<br>
                src/PluginManager.cpp a9a1c47<br>
                src/CMakeLists.txt afeef4a<br>
                src/MainWindow.cpp d3bbc0b<br>
                src/App.cpp 6028bc8<br>
              <br>
              Diff: <a moz-do-not-send="true"
                href="https://git.reviewboard.kde.org/r/125126/diff/"
                rel="noreferrer" target="_blank">https://git.reviewboard.kde.org/r/125126/diff/</a><br>
              <br>
              <br>
              Testing (updated)<br>
              -------<br>
              <br>
              It compiles 100%, and there is a segmentation fault after
              the end of the App::continueInit().<br>
              <br>
              I'm not able to trace it further.<br>
              <br>
            </blockquote>
            <div>
              <div><br>
                <br>
                hello olivier,<br>
                <br>
              </div>
              <div>I can try to help you out but could you please
                explain the last changes that you have made . Just a
                brief explanation about what was causing the seg fault
                and what did you do  to solve it . I understood the
                changes that involved changing of Kuniqueapplication to
                Qapplication but the one's you made after that,i have
                just applied them ,so right now i am getting the same
                error as you are. You have alreay ported much of the
                main and app class what else needs to be done?<br>
              </div>
            </div>
          </div>
        </div>
      </div>
    </blockquote>
    Fair enough, I didn't say a word about this :)<br>
    <br>
    So my goal was to port the main and the App class to KF5/Qt5. So as
    you said, it involve mostly to move from KUniqueApplication to
    QApplication. I did this. You have to know that KUniqueApplication
    is just an extension of QApplication (through KAppplication) which
    does a DBus registration in order to know how many instance are or
    can be started. So I added also a KDBusService to register the
    instance.<br>
    <br>
    The porting seems to work well BUT I didn't take in account the fact
    that you might want to use the --play --pause (and so on) CLI
    commands. This should be put in the activateRequested() slot, but
    I'm not really sure how this should be done.<br>
    <br>
    The second thing is that I'm not sure if I ported everything right,
    or not, since I don't have an deep knowledge of KDBus and all this
    process.<br>
    <br>
    Then, when it compiled well, I started to track the segfault.
    Basically, you start amarok with --debug and you track where it
    stops. But it's not enough, so I added qDebug() << "a
    recognizable comment" everywhere to know where it stops (first in
    the main then in App::App(), then in App::continueEdit() and so on
    recursively.<br>
    <br>
    My last segfault (with the patch I send) occurs after the end of
    App::continueEdit(), meaning it might come from a slot somewhere,
    called by one of all the signal that could be sent.<br>
    <br>
    Now you know as much as I do. Pleas ask further if I'm not clear
    enough :)<br>
    <blockquote
cite="mid:CAB9YDnW68=-yrxYOgaHioYMTXbVtj-SU8vt25BK9ocUP_JQObQ@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div class="gmail_extra">
          <div class="gmail_quote">
            <div>here's the output <br>
              <a moz-do-not-send="true"
                href="http://pastebin.com/5StyEUth">http://pastebin.com/5StyEUth</a><br>
            </div>
          </div>
        </div>
      </div>
    </blockquote>
    Huuu.... Wait, it's not possible. My segfault doesn't happen in
    handleCliArgs() but way after... It means that I left a bug, that
    works on my system but not yours OR that something is wrong on your
    side. Please investigate why this happen, I'll do this on my side
    too.<br>
    <br>
    Cheers,<br>
    Olivier<br>
    <blockquote
cite="mid:CAB9YDnW68=-yrxYOgaHioYMTXbVtj-SU8vt25BK9ocUP_JQObQ@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div class="gmail_extra">
          <div class="gmail_quote">
            <div><br>
              <br>
               </div>
            <blockquote class="gmail_quote" style="margin:0px 0px 0px
              0.8ex;border-left:1px solid
              rgb(204,204,204);padding-left:1ex">
              <br>
              Thanks,<br>
              <br>
              Olivier Churlaud<br>
              <br>
            </blockquote>
            <div>thanks,<br>
            </div>
            <div>rishabh <br>
            </div>
            <blockquote class="gmail_quote" style="margin:0px 0px 0px
              0.8ex;border-left:1px solid
              rgb(204,204,204);padding-left:1ex">
              <br>
            </blockquote>
          </div>
          <br>
        </div>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
Amarok-devel mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Amarok-devel@kde.org">Amarok-devel@kde.org</a>
<a class="moz-txt-link-freetext" href="https://mail.kde.org/mailman/listinfo/amarok-devel">https://mail.kde.org/mailman/listinfo/amarok-devel</a>
</pre>
    </blockquote>
    <br>
  </body>
</html>