Plug-in "Compare" - bug
-
Hello @Mi-Me,
can you try to replicate this being compare the only plugin?
I tried it several times, even by pressing alt+d for ~30 seconds,
but didn’t crash my npp 6.8.8 on windows 7 x64.Cheers
Claudia -
Thank you, Claudia.
Unfortunately this bug easily reproduced on all computers I have access to… - 4.Steps are the following.
- Open Notepad++ with “new1”
- Write “abcd”
- Double click on bar to open “new2”
- write “bcde”
- Alt+D
- Double click on one side to open “new3”…
– write there - Double click on other side to open “new4”
–write there something
And please do steps 6 and 7 in cycle with pressing (holding) periodically Alt+D.
If it will not help to reproduce this bug - I will write Screen video…
Thank you in advance.
Best wishes,
Michael -
Hello Michael,
I did test it like you’d advised but wasn’t able to produce the crash.
Even you do compare action doesn’t necessarily mean this plugin
is the cause of the problem it might be that another plugin does
something in parallel which might result in the crash.If you could test with being compare plugin the one and only plugin loaded,
we can, more or less, be sure that this plugin is the reason of the crash.Cheers
Claudia -
Dear Claudia,
please, have a look on the screen-shots and video. There on dropbox: couple of screen-shots and video-file
The strange behavior of Notepad++, when you start compare New1 (with some text) with blank New2.
Thank you for your patience and your help.
Best wishes,
Michael. -
Hello Michael and Claudia,
The “nul” added to new blank files is a known issue.
Some questions:
- I assume you’re using NPP 6.8.8. Is that correct?
- Which Compare version are you using? Can you try other versions?
- Have you tried removing any other plugins as Claudia has suggested?
- Does the crash occur if the NavBar is closed?
- Does it occur if you use Plugins -> Compare -> Compare (i.e. instead of Alt+D)?
- It’s not clear if it happens only after typing something in the new file.
- What do you mean “pressing (holding) periodically Alt+D”?
Best regards.
-
Hello Michael,
yes, confirmed - the trick to crash npp is that one of the files to compare is empty.
To reproduce the following needs to be doneNpp gets started with an empty new 1 document.
Write something into new 1
open a second empty document (new 2)
go back to new 1
press ALT+Dyou see that there is garbage in the new 2 doc, move the mouse to this line -> npp crash
I guess this isn’t really a use case for compare plugin but it obviously shouldn’t crash npp.
From generated dump it looks like scintilla is causing the crash.
ExceptionAddress: 0f79e951 (SciLexer+0x0001e951)
ExceptionCode: c0000005 (Access violation)
ExceptionFlags: 00000000
NumberParameters: 2
Parameter[0]: 00000001
Parameter[1]: fffffffc
Attempt to write to address fffffffcBut why is it trying to write to this address ??
By the way, test was made with npp 6.8.8 minimalistic and compare plugin being the only plugin.
Cheers
Claudia -
Hello Yaron,
regardless whether navbar is active or not, and
it doesn’t make a difference if using ALT+D or compare via menu,
crash happens.Cheers
Claudia -
Hello Claudia,
Precise and clear as always. :)
Thank you.I can reproduce it with 1.5.6.6 (and earlier versions) but not with 1.5.6.7.
It’s interesting which of UFO’s modifications makes the difference.
Could you please try it?BTW, NPP crashes in some rare cases when using “Compare to last save”.
I hardly use that command and haven’t properly tested it.Best regards.
-
Hello Yaron,
you are right, 1.5.6.7 doesn’t crash npp when having an empty doc but
still fills it with a NUL ( but I saw you already opened an issue for this ).To be honest, I use only basic compare functionality ALT+D and ALT+CTRL+D ;-)
Thank you
Claudia -
Hello Claudia,
Thank you for testing it.
And many thanks again for your great contribution on the forum. :)Best regards.
-
Hello Yaron,
no problem, btw I would bet that the changes made on the 14th of january
in compare.cpp line 988 - 1000 fixed it.Cheers
Claudia -
Hello Claudia,
As I’ve written before: “Sherlock Holmes!”. Amazing.
Well, I’m running out of superlatives. :)Thank you so much.