Forward patch of fix for bug 418, svn revision 2600