Index: /CKEditor/branches/versions/3.4.x/_source/plugins/selection/plugin.js
===================================================================
--- /CKEditor/branches/versions/3.4.x/_source/plugins/selection/plugin.js	(revision 5792)
+++ /CKEditor/branches/versions/3.4.x/_source/plugins/selection/plugin.js	(revision 5793)
@@ -1041,5 +1041,5 @@
 			{
 				this._.cache.selectedElement = null;
-				this._.cache.startElement = ranges[ 0 ].getTouchedStartNode();
+				this._.cache.startElement = ranges[ 0 ] && ranges[ 0 ].getTouchedStartNode();
 				this._.cache.ranges = new CKEDITOR.dom.rangeList( ranges );
 				this._.cache.type = CKEDITOR.SELECTION_TEXT;
