Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 241214 - [Patch] An error while saving a patch file
Summary: [Patch] An error while saving a patch file
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: CVS (show other bugs)
Version: 3.4   Edit
Hardware: All All
: P3 minor (vote)
Target Milestone: 3.5 M1   Edit
Assignee: Pawel Pogorzelski CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-07-17 05:40 EDT by Tomasz Zarna CLA
Modified: 2009-06-02 06:50 EDT (History)
0 users

See Also:


Attachments
Patch (4.55 KB, patch)
2008-07-17 09:21 EDT, Pawel Pogorzelski CLA
no flags Details | Diff
Patch (6.27 KB, patch)
2008-07-22 11:18 EDT, Pawel Pogorzelski CLA
pawel.pogorzelski1: iplog+
Details | Diff
Fix v03 (5.66 KB, patch)
2008-07-23 08:14 EDT, Tomasz Zarna CLA
no flags Details | Diff
mylyn/context/zip (4.45 KB, application/octet-stream)
2008-07-23 08:14 EDT, Tomasz Zarna CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Tomasz Zarna CLA 2008-07-17 05:40:46 EDT
When checking a patch for bug 214105 I came across an issue. The steps are as follows:
1. Modify a shared project
2. Create a patch
3. Select "Workspace" as the location of the patch
4. Click "Browse..."
5. The "Save Patch" dialog shows up
6. Select a project with a folder
7. Enter the same name for the file as the folder. OK button is enabled which is fine as you should be able to create such a file.
8. Click OK, and then Finish on the wizard
=> first you'll get a message saying "A file with that name already exist", which is misleading (unless we treat all folder as files)
=> when accepted, you'll get an error message "Problem Occurred: Resource exists". I know, you've just told me that :)
=> creating the patch fails
Comment 1 Pawel Pogorzelski CLA 2008-07-17 09:21:16 EDT
Created attachment 107729 [details]
Patch

Tomasz, I fix the problem. Please have a look at the patch.
Comment 2 Pawel Pogorzelski CLA 2008-07-17 09:26:57 EDT
One more comment. I fixed the problem by disabling the OK button when the user specified a path that points to a folder. I also added the same behavior to the parent control where you can type the whole path.
Comment 3 Tomasz Zarna CLA 2008-07-21 05:51:08 EDT
The patch seems to be incomplete. It's missing CVSUIMessages.GenerateDiffFileWizard_FolderExists message, which leads to compilation errors.
Comment 4 Pawel Pogorzelski CLA 2008-07-22 11:18:11 EDT
Created attachment 108077 [details]
Patch

This one should be fine.
Comment 5 Tomasz Zarna CLA 2008-07-23 08:14:32 EDT
Created attachment 108185 [details]
Fix v03

The latest patch works fine, but I made some cosmetic changes in it. How does it look now, Pawel?
Comment 6 Tomasz Zarna CLA 2008-07-23 08:14:38 EDT
Created attachment 108186 [details]
mylyn/context/zip
Comment 7 Pawel Pogorzelski CLA 2008-07-23 08:29:52 EDT
Looks nice. Thanks.
Comment 8 Tomasz Zarna CLA 2008-07-28 03:36:10 EDT
The latest version of Pawel's patch (v03) released to HEAD.