Community
Participate
Working Groups
Build Identifier: M20110909-1335 If you pass in a URI containing an unsupported scheme id (such as "ftp") into the method RemoteFileProxy#getFileProxy(URI uri), instead of returning a null, it will always silently return the local file proxy. Reproducible: Always Steps to Reproduce: N/A
Created attachment 210158 [details] Fix problem with URI's containing unsupported scheme ids.
(In reply to comment #1) > Created attachment 210158 [details] > Fix problem with URI's containing unsupported scheme ids. Would it not be better to throw a CoreException? I believe this is how I did it for the CDT RDT branch.
(In reply to comment #2) > (In reply to comment #1) > > Created attachment 210158 [details] > > Fix problem with URI's containing unsupported scheme ids. > > Would it not be better to throw a CoreException? I believe this is how I did > it for the CDT RDT branch. If you'd like all error handling to be done via exception, that's fine with me. Do you want me to re-write the patch?
(In reply to comment #3) > (In reply to comment #2) > > (In reply to comment #1) > > > Created attachment 210158 [details] > > > Fix problem with URI's containing unsupported scheme ids. > > > > Would it not be better to throw a CoreException? I believe this is how I did > > it for the CDT RDT branch. > > If you'd like all error handling to be done via exception, that's fine with me. > Yes. Otherwise, every call to get proxy managers has to check for null which is tedious. There already has to be exception handling for using the proxies so it would be a cleaner design. > Do you want me to re-write the patch? Sure. The more patches you have accepted, the easier it is to nominate you as a committer.
Created attachment 210294 [details] Patch to improve error handling of getFileProxy when passed a URI containing an unsupported scheme id I wrote this patch myself, and I have the permission of my employer to submit it.
Is there anything else to change in this patch? I tested this and it is working fine for me. Can you apply it?
(In reply to comment #6) > Is there anything else to change in this patch? I tested this and it is working > fine for me. Can you apply it? Just looking at it now, it needs the EPL license added for the new files: Messages.java and messages.properties. Other than that, it is good to apply as it is <250 lines.
The changes in this patch are intended to be EPL 1.0. Would it be OK for Otavio to add the EPL license info into the patch instead of me. I give him permission to do so, if that's needed, or he can create a new patch with his name on it instead, and include the EPL. It doesn't matter to me.
(In reply to comment #8) > The changes in this patch are intended to be EPL 1.0. > > Would it be OK for Otavio to add the EPL license info into the patch instead of > me. I give him permission to do so, if that's needed, or he can create a new > patch with his name on it instead, and include the EPL. It doesn't matter to > me. Yes, that would be fine. Otavio please post the updated patch here.
Created attachment 215714 [details] RemoteProxyManager: improve error handling of getFileProxy bug
I updated the patch and it is not creating new files anymore, so it was not necessary to add the epl license. All .java files it changes are already with epl header.
(In reply to comment #11) > I updated the patch and it is not creating new files anymore, so it was not > necessary to add the epl license. All .java files it changes are already with > epl header. Ok, feel free to commit.
commit hash: 2bdc917bab72726822bc191f11458a45f00f8a0c