cornercorner
FeaturesPluginsDocs & SupportCommunityPartners

Bug 124966 - NullPointerException when click Revert button
: NullPointerException when click Revert button
Status: VERIFIED FIXED
: versioncontrol
Mercurial
: 6.1
: PC Windows XP
: P3 (vote)
: 6.1
Assigned To:
:
: http://statistics.netbeans.org/analyt...
:
:
:
:
  Show dependency treegraph
 
Reported: 2008-01-09 15:45 by
Modified: 2008-01-18 07:26 (History)
Issue Type: DEFECT
:


Attachments
Proposed patch (1.23 KB, text/plain)
2008-01-16 17:04, John Rice
Details


Note

You need to log in before you can comment on or make changes to this bug.


Description From 2008-01-09 15:45:29
NPE is thrown when you click Revert button and revisions are not yet resolved.
To reproduce:

- open a file versioned in Mercurial
- make a local change and save file
- call "Mercurial|Revert Modifications" and immediatelly click Revert button.
The exception is thrown probably because
combo box with revisions is not yet populated.

Mercurial Pluging: 1.4.3.42.1
Mercurial Runtime: 0.9.5
Product Version: NetBeans IDE Dev (Build 20080109120642)
Java: 1.6.0_04; Java HotSpot(TM) Client VM 10.0-b19
System: Windows XP version 5.1 running on x86; Cp1250; cs_CZ (nb)
Userdir: D:\Development\builds\nbUserdir-Hg
------- Comment #1 From 2008-01-16 16:57:50 -------
Can't reproduce - can you attach a stack trace.
------- Comment #2 From 2008-01-16 17:04:51 -------
Created an attachment (id=55159) [details]
Proposed patch
------- Comment #3 From 2008-01-16 17:06:39 -------
Checked to see where this could be arising and have added check for null
revision string. The revert will still work but
it will just default to the following action:

    With no revision specified, revert the named files or directories
    to the contents they had in the parent of the working directory.
------- Comment #4 From 2008-01-16 17:09:46 -------
IDE:-------------------------------------------------
IDE: [16/01/08 17:09] Committing started
Checking in RevertModificationsPanel.java;
/shared/data/ccvs/repository/versioncontrol/mercurial/src/org/netbeans/modules/mercurial/ui/update/RevertModificationsPanel.java,v
 <--  RevertModificationsPanel.java
new revision: 1.8; previous revision: 1.7
done
IDE: [16/01/08 17:09] Committing finished
IDE: [16/01/08 17:09] Diffing finished
------- Comment #5 From 2008-01-18 07:26:23 -------
Verified.