Announcement

Collapse
No announcement yet.

BComp exits too early

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • BComp exits too early

    Hi Support Team,

    I am the developer of the PVCSmerge tool providing the use of Beyond Compare as comparison tool within PVCS / Merant Dimensions. A user informed me about a problem and I did some analyses. I'd like to explain what I've found.

    In detail my tool calls BCompare.exe to display the comparison. If the process ends it deletes the temp files. BC 3 introduce tabs: In case Beyond Compare is already running there is no new process to create; instead the already runnnig BCompare process is used. This leads to a too early deleted temp file (because CreateProcess and a following WaitForSingleObject returns too early).

    It seems that you already solved this problem - in BComp.exe. If I use this for comparison this problem is absent. But not for ZIP files (and files with a file extension configured in Options/Folders/Archive assignments). If BComp.exe is called with such a ZIP file it exits too early and therefore my tool deletes the temp file before BC 3 has loaded it. I can workaround it by postponing the deletion - but I think it should be solved in general...


    The short form of where I'd like to draw your attention to is:
    - comparison of two text files - BComp.exe waits until BCompare.exe exits
    - comparison of two archives - BComp.exe starts BCompare and immediately exits


    More details are provided with the following examples:

    1. BComp.exe is called to compare two pas files:

    "C:\Program Files (x86)\Beyond Compare 3\BComp.exe" "F:\Compiler\Delphi\Utils\Sudoku\uSudoku.pas" "C:\Users\Michael\AppData\Local\Temp\pvcs\_te79xj4 7.pas" /title1="uSudoku.pas (workfile)" /title2="uSudoku.pas (Rev. 1.2)" /rro

    BComp then performs the following command:

    "C:\Program Files (x86)\Beyond Compare 3\BComp.exe" "F:\Compiler\Delphi\Utils\Sudoku\uSudoku.pas" "C:\Users\Michael\AppData\Local\Temp\pvcs\_te79xj4 7.pas" /title1="uSudoku.pas (workfile)" /title2="uSudoku.pas (Rev. 1.2)" /rro /BCompWnd=$00090ADE

    If I close the Beyond Compare window, both processes end.
    Besides: I can use ESC to close / exit the comparison tab.


    2. BComp.exe is called to compare two mpb files. I have configured MPB files to be treated as ZIP files in the above mentioned options section (I changed the value to "*.zip;*.jar;*.ear;*.war;*.bcpkg;*.mpb;*.hmxz" ):

    I cannot grab the command line from Process Explorer because it disappears too fast. But I can see the BComp.exe process creates the BComprare.exe process. It remains in the Process Explorer window (without a parent process) and therefore I can see the command line used to create the process:

    "C:\Program Files (x86)\Beyond Compare 3\BComp.exe" "F:\Compiler\Delphi\Utils\Sudoku\Sudoku.mpb" "C:\Users\Michael\AppData\Local\Temp\pvcs\_7dcin44 9.mpb" /title1="Sudoku.mpb (workfile)" /title2="Sudoku.mpb (Rev. 1.2)" /rro /BCompWnd=$00050B0C

    BComp.exe is already disappeared, and this BCompare.exe disappears in case I close the comparison.
    Besides: here I cannot use ESC to close / exit the comparison.



    Is this helpful for you or do you disagree that this is a bug?

    Best regards
    Michael
    Last edited by Schnaddel; 07-Oct-2011, 02:20 PM.

  • #2
    Hello,

    BC3 does not currently support the wait for a pair of folders (Folder Compare). If you point to a custom BComp.cmd, with these contents:
    "C:\Program Files (x86)\Beyond Compare 3\BComp.exe" %*
    pause

    How does this work for you?
    Aaron P Scooter Software

    Comment


    • #3
      Hi Aaron,

      thank you for your quick response.

      The solution might work fine, but I'd like to provide a more convenient solution (without the need to manually close a Command Window each time a comparison was requested).

      This is already completed - I'd like to let the mentioned user check the new version. Most likely I'll provide you / other users with the new version on monday...

      Best regards
      Michael

      Comment

      Working...
      X