Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 1782 Details for
Bug 12463
Plugin.find(IPath path, Map override) searches wrong directories
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Attached patch for fix. Same as in-line patch in previous comment.
patch.txt (text/plain), 2.04 KB, created by
Dorian Birsan
on 2002-08-01 10:25:49 EDT
(
hide
)
Description:
Attached patch for fix. Same as in-line patch in previous comment.
Filename:
MIME Type:
Creator:
Dorian Birsan
Created:
2002-08-01 10:25:49 EDT
Size:
2.04 KB
patch
obsolete
>Index: PluginDescriptor.java >=================================================================== >RCS file: /home/eclipse/org.eclipse.core.runtime/src/org/eclipse/core/internal/plugins/PluginDescriptor.java,v >retrieving revision 1.32 >diff -u -r1.32 PluginDescriptor.java >--- PluginDescriptor.java 23 Jul 2002 13:54:34 -0000 1.32 >+++ PluginDescriptor.java 1 Aug 2002 14:24:02 -0000 >@@ -45,6 +45,8 @@ > // Places to look for library files > private static String[] WS_JAR_VARIANTS = buildWSVariants(); > private static String[] OS_JAR_VARIANTS = buildOSVariants(); >+ // Next static var is not really needed. >+ // At best, for performance reasons, one could create a hashtable of nl_jar_variants, indexed by locale. > private static String[] NL_JAR_VARIANTS = buildNLVariants(); > private static String[] JAR_VARIANTS = buildVanillaVariants(); > >@@ -65,7 +67,12 @@ > return (String[])result.toArray(new String[result.size()]); > } > private static String[] buildNLVariants() { >- String nl = BootLoader.getNL(); >+ return buildNLVariants(BootLoader.getNL()); >+} >+private static String[] buildNLVariants(String nl) { >+ // Theoretically, we could create a hash table of all the nl variants >+ // built, indexed by the nl string. This would avoid extra computation >+ // and memory allocation. > ArrayList result = new ArrayList(); > IPath base = new Path("nl"); //$NON-NLS-1$ > >@@ -909,6 +916,7 @@ > > private URL findNL(URL install, IPath path, Map override) { > String nl = null; >+ > if (override != null) > try { > // check for override >@@ -923,8 +931,9 @@ > return null; > > URL result = null; >- for (int i=0; i<NL_JAR_VARIANTS.length; i++) { >- IPath filePath = new Path(NL_JAR_VARIANTS[i]).append(path); >+ String[] nl_jar_variants = buildNLVariants(nl); >+ for (int i=0; i<nl_jar_variants.length; i++) { >+ IPath filePath = new Path(nl_jar_variants[i]).append(path); > result = findInPlugin(install, filePath); > if (result != null) > return result; >@@ -980,4 +989,4 @@ > } > return null; > } >-} >+} >\ No newline at end of file
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 12463
: 1782