Index: /trunk/src/VBox/Main/glue/glue-java.xsl
===================================================================
--- /trunk/src/VBox/Main/glue/glue-java.xsl	(revision 53385)
+++ /trunk/src/VBox/Main/glue/glue-java.xsl	(revision 53386)
@@ -159,5 +159,5 @@
     </xsl:when>
     <xsl:otherwise>
-      <xsl:variable name="end" select="substring($text, string-length($text) - 1, 1)"/>
+      <xsl:variable name="end" select="substring($text, string-length($text), 1)"/>
       <xsl:choose>
         <xsl:when test="$end = ' ' or $end = '&#10;' or $end = '&#13;'">
