Index: /home/herve/projet/workspace/maven-reporting-impl/src/main/java/org/apache/maven/reporting/AbstractMavenReportRenderer.java
===================================================================
--- /home/herve/projet/workspace/maven-reporting-impl/src/main/java/org/apache/maven/reporting/AbstractMavenReportRenderer.java	(revision 514240)
+++ /home/herve/projet/workspace/maven-reporting-impl/src/main/java/org/apache/maven/reporting/AbstractMavenReportRenderer.java	(working copy)
@@ -21,9 +21,11 @@
 import org.apache.maven.doxia.sink.Sink;
 import org.codehaus.plexus.util.StringUtils;
 
+import java.util.ArrayList;
 import java.util.Collections;
 import java.util.Iterator;
 import java.util.LinkedHashMap;
+import java.util.List;
 import java.util.Map;
 import java.util.Properties;
 
@@ -350,7 +352,7 @@
         }
         else
         {
-            Map segments = applyPattern( text );
+            List segments = applyPattern( text );
 
             if ( segments == null )
             {
@@ -358,12 +360,10 @@
             }
             else
             {
-                for ( Iterator it = segments.entrySet().iterator(); it.hasNext(); )
+                for ( Iterator it = segments.iterator(); it.hasNext(); )
                 {
-                    Map.Entry entry = (Map.Entry) it.next();
-
-                    String name = (String) entry.getKey();
-                    String href = (String) entry.getValue();
+                    String name = (String) it.next();
+                    String href = (String) it.next();
 
                     if ( href == null )
                     {
@@ -507,12 +507,12 @@
 
     /**
      * The method parses a text an apply the given pattern <code>{text, url}</code> to create
-     * a map of text/href.
+     * a list of text followed by href.
      *
      * @param text a text with or without the pattern <code>{text, url}</code>
-     * @return a map of text/href
+     * @return a list of text then href (href can be null)
      */
-    private static Map applyPattern( String text )
+    static List applyPattern( String text )
     {
         if ( StringUtils.isEmpty( text ) )
         {
@@ -521,7 +521,7 @@
 
         // Map defined by key/value name/href
         // If href == null, it means
-        Map segments = new LinkedHashMap();
+        List segments = new ArrayList();
 
         // TODO Special case http://jira.codehaus.org/browse/MEV-40
         if ( text.indexOf( "${" ) != -1 )
@@ -530,11 +530,13 @@
             int lastSemi = text.lastIndexOf( "}" );
             if ( lastComma != -1 && lastSemi != -1 )
             {
-                segments.put( text.substring( lastComma + 1, lastSemi ).trim(), null );
+                segments.add( text.substring( lastComma + 1, lastSemi ).trim() );
+                segments.add( null );
             }
             else
             {
-                segments.put( text, null );
+                segments.add( text );
+                segments.add( null );
             }
 
             return segments;
@@ -550,12 +552,15 @@
 
             if ( ch == '\'' && !inQuote )
             {
-                // handle: ''
-                if ( i + 1 < text.length() && text.charAt( i + 1 ) == '\'' )
+                // remove quote
+                if ( i + 1 >= text.length() )
                 {
-                    i++;
+                  throw new IllegalArgumentException( "Unmatched quote in the pattern." );
                 }
-                else
+                text = text.substring( 0, i ) + text.substring( i + 1 );
+
+                // handle: ''
+                if ( i >= text.length() || text.charAt( i ) != '\'' )
                 {
                     inQuote = true;
                 }
@@ -571,11 +576,12 @@
                             {
                                 if ( i != 0 ) // handle { at first character
                                 {
-                                    segments.put( text.substring( lastOffset, i ), null );
+                                    segments.add( text.substring( lastOffset, i ) );
+                                    segments.add( null );
                                 }
                                 lastOffset = i + 1;
-                                braceStack++;
                             }
+                            braceStack++;
                         }
                         break;
                     case '}':
@@ -588,14 +594,14 @@
                                 lastOffset = i + 1;
 
                                 int lastComma = subString.lastIndexOf( "," );
+                                segments.add( subString.substring( 0, lastComma ).trim() );
                                 if ( lastComma != -1 )
                                 {
-                                    segments.put( subString.substring( 0, lastComma ).trim(),
-                                                  subString.substring( lastComma + 1 ).trim() );
+                                    segments.add( subString.substring( lastComma + 1 ).trim() );
                                 }
                                 else
                                 {
-                                    segments.put( subString.substring( 0, lastComma ).trim(), null );
+                                    segments.add( null );
                                 }
                             }
                         }
@@ -602,6 +608,14 @@
                         break;
                     case '\'':
                         inQuote = false;
+                        if ( i + 1 < text.length() )
+                        {
+                            text = text.substring( 0, i ) + text.substring( i + 1 );
+                        }
+                        else
+                        {
+                            text = text.substring( 0, i );
+                        }
                         break;
                     default:
                         break;
@@ -611,7 +625,8 @@
 
         if ( !StringUtils.isEmpty( text.substring( lastOffset, text.length() ) ) )
         {
-            segments.put( text.substring( lastOffset, text.length() ), null );
+            segments.add( text.substring( lastOffset, text.length() ) );
+            segments.add( null );
         }
 
         if ( braceStack != 0 )
@@ -619,7 +634,12 @@
             throw new IllegalArgumentException( "Unmatched braces in the pattern." );
         }
 
-        return Collections.unmodifiableMap( segments );
+        if ( inQuote )
+        {
+            throw new IllegalArgumentException( "Unmatched quote in the pattern." );
+        }
+
+        return Collections.unmodifiableList( segments );
     }
 
     public abstract String getTitle();

