Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIan Bull2012-03-09 19:37:06 +0000
committerIan Bull2012-03-09 19:37:06 +0000
commit707e5cba396765ca92b1e7be56a17aeb1fbb97a6 (patch)
tree4f7605fd4d8822bb0c2f2501286ceee9c291ffbe
parentf46d28f002d22977657a570398f003e8fd2ed026 (diff)
downloadrt.equinox.p2-707e5cba396765ca92b1e7be56a17aeb1fbb97a6.tar.gz
rt.equinox.p2-707e5cba396765ca92b1e7be56a17aeb1fbb97a6.tar.xz
rt.equinox.p2-707e5cba396765ca92b1e7be56a17aeb1fbb97a6.zip
Bug 373825 - AIOOBE when publishing a product with version "0.0.0" forv20120309-1937
MacOS X Checks for segment length before assuming we have a segment(0).
-rw-r--r--bundles/org.eclipse.equinox.p2.publisher.eclipse/src/org/eclipse/equinox/internal/p2/publisher/eclipse/BrandingIron.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/bundles/org.eclipse.equinox.p2.publisher.eclipse/src/org/eclipse/equinox/internal/p2/publisher/eclipse/BrandingIron.java b/bundles/org.eclipse.equinox.p2.publisher.eclipse/src/org/eclipse/equinox/internal/p2/publisher/eclipse/BrandingIron.java
index 90b967386..b2abf798e 100644
--- a/bundles/org.eclipse.equinox.p2.publisher.eclipse/src/org/eclipse/equinox/internal/p2/publisher/eclipse/BrandingIron.java
+++ b/bundles/org.eclipse.equinox.p2.publisher.eclipse/src/org/eclipse/equinox/internal/p2/publisher/eclipse/BrandingIron.java
@@ -531,7 +531,7 @@ public class BrandingIron {
if (version != null) {
// CFBundleShortVersionString is to be 3 segments only
// http://developer.apple.com/library/mac/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html#//apple_ref/doc/uid/20001431-111349
- StringBuffer sv = new StringBuffer(version.getSegment(0).toString());
+ StringBuffer sv = new StringBuffer(version.getSegmentCount() > 0 ? version.getSegment(0).toString() : "0"); //$NON-NLS-1$
sv.append('.');
sv.append(version.getSegmentCount() > 1 ? version.getSegment(1).toString() : "0"); //$NON-NLS-1$
sv.append('.');

Back to the top