BUG#28804 fix ha_ndbcluster::unique_index_read to properly return error

On error during unique index read, set table->status appropriately.
This ensures the user gets the correct error from NDB.

The okay error is still, of course, STATUS_NOT_FOUND

===== sql/ha_ndbcluster.cc 1.313 vs edited =====
Index: ndb-work/sql/ha_ndbcluster.cc
===================================================================
--- ndb-work.orig/sql/ha_ndbcluster.cc	2007-06-29 17:57:17.284421007 +1000
+++ ndb-work/sql/ha_ndbcluster.cc	2007-06-29 17:59:36.752368833 +1000
@@ -1758,9 +1758,15 @@ int ha_ndbcluster::unique_index_read(con
 
   if (execute_no_commit_ie(this,trans,false) != 0) 
   {
-    table->status= STATUS_NOT_FOUND;
-    DBUG_RETURN(ndb_err(trans));
+    int err= ndb_err(trans);
+    if(err==120)
+      table->status= STATUS_NOT_FOUND;
+    else
+      table->status= STATUS_GARBAGE;
+
+    DBUG_RETURN(err);
   }
+
   // The value have now been fetched from NDB
   unpack_record(buf);
   table->status= 0;
