Index: /CKEditor/trunk/_source/plugins/table/dialogs/table.js
===================================================================
--- /CKEditor/trunk/_source/plugins/table/dialogs/table.js	(revision 7415)
+++ /CKEditor/trunk/_source/plugins/table/dialogs/table.js	(revision 7416)
@@ -32,4 +32,23 @@
 
 		return maxCols;
+	}
+
+
+	// Whole-positive-integer validator.
+	function validatorNum( msg )
+	{
+		return function()
+		{
+			var value = this.getValue(),
+				pass = !!( CKEDITOR.dialog.validate.integer()( value ) && value > 0 );
+
+			if ( !pass )
+			{
+				alert( msg );
+				this.select();
+			}
+
+			return pass;
+		};
 	}
 
@@ -282,17 +301,5 @@
 											required : true,
 											controlStyle : 'width:5em',
-											validate : function()
-											{
-												var value = this.getValue(),
-													pass = !!( CKEDITOR.dialog.validate.integer()( value ) && value > 0 );
-
-												if ( !pass )
-												{
-													alert( editor.lang.table.invalidRows );
-													this.select();
-												}
-
-												return pass;
-											},
+											validate : validatorNum( editor.lang.table.invalidRows ),
 											setup : function( selectedElement )
 											{
@@ -308,17 +315,5 @@
 											required : true,
 											controlStyle : 'width:5em',
-											validate : function()
-											{
-												var pass = true,
-													value = this.getValue();
-												pass = pass && CKEDITOR.dialog.validate.integer()( value )
-													&& value > 0;
-												if ( !pass )
-												{
-													alert( editor.lang.table.invalidCols );
-													this.select();
-												}
-												return pass;
-											},
+											validate : validatorNum( editor.lang.table.invalidCols ),
 											setup : function( selectedTable )
 											{
