Fix for potential buffer-underrun and partial fix for XALANC-666.
Fix for potential buffer-underrun and partial fix for XALANC-666.

git-svn-id: b36ee6b6e70810a25e81bc801db00a83677983fc@649853 13f79535-47bb-0310-9956-ffa450edef68

AaronNGray/xalan,AaronNGray/xalan,AaronNGray/xalan,AaronNGray/xalan