=== modified file includes/form.inc
--- includes/form.inc	2010-09-09 13:50:11.000000000 +0530
+++ includes/form.inc	2010-09-09 13:52:12.000000000 +0530
@@ -2827,7 +2827,10 @@ function form_process_tableselect($eleme
     }
 
     // Sort the options by their #weight if they have a #weight.
-    uasort($element['#options'], 'element_sort');
+    // Assumes that all options are either weighted or all un-weighted
+    if(array_key_exists('#weight',pos($element['#options']))){ 
+      uasort($element['#options'], 'element_sort');
+    }
     // Create a checkbox or radio for each item in #options in such a way that
     // the value of the tableselect element behaves as if it had been of type
     // checkboxes or radios.
