Index: /CKEditor/trunk/_source/core/dom/element.js
===================================================================
--- /CKEditor/trunk/_source/core/dom/element.js	(revision 3629)
+++ /CKEditor/trunk/_source/core/dom/element.js	(revision 3630)
@@ -1116,5 +1116,5 @@
 			else
  			{
-				var current = this, previous = null;
+				var current = this, previous = null, offsetParent;
 				while ( current && !( current.getName() == 'body' || current.getName() == 'html' ) )
 				{
@@ -1137,7 +1137,7 @@
 					}
 
-					previous = current;
-					current = new CKEDITOR.dom.element( current.$.offsetParent );
-				}
+				previous = current;
+				current = ( offsetParent = current.$.offsetParent ) ?
+				  new CKEDITOR.dom.element( offsetParent ) : null;
 			}
 
Index: /CKEditor/trunk/_source/plugins/enterkey/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/enterkey/plugin.js	(revision 3629)
+++ /CKEditor/trunk/_source/plugins/enterkey/plugin.js	(revision 3630)
@@ -262,5 +262,5 @@
 			// We need some text inside of it, so the bogus <br> is properly
 			// created.
-			if ( CKEDITOR.env.gecko )
+			if ( !CKEDITOR.env.ie )
 				doc.createText( '\ufeff' ).insertAfter( lineBreak );
 
@@ -271,7 +271,6 @@
 			// Now we can remove the text node contents, so the caret doesn't
 			// stop on it.
-			if ( CKEDITOR.env.gecko )
+			if ( !CKEDITOR.env.ie )
 				lineBreak.getNext().$.nodeValue = '';
-
 			// IE has different behavior regarding position.
 			if ( CKEDITOR.env.ie )
@@ -285,6 +284,12 @@
 				var dummy = null;
 
-				if ( CKEDITOR.env.opera )
+				// BR is not positioned in Opera and Webkit.
+				if ( !CKEDITOR.env.gecko )
+				{
 					dummy = doc.createElement( 'span' );
+					// We need have some contents for Webkit to position it
+					// under parent node. ( #3681)
+					dummy.setHtml('&nbsp;');
+				}
 				else
 					dummy = doc.createElement( 'br' );
