Update of /cvsroot/monetdb/sql/src/server
In directory 23jxhf1.ch3.sourceforge.com:/tmp/cvs-serv12820/src/server

Modified Files:
        sql_schema.mx 
Log Message:
propagated changes of Wednesday Aug 12 2009
from the Aug2009 branch to the development trunk

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2009/08/12 - stmane: src/server/sql_schema.mx,1.177.2.1

In an attampt to ensure portability to, and hence correctness on,
64-bit big-endian machines with 32-bit OIDs,
we make the SQL storage interface implementation a bit "less generic",
but a bit "more MonetDB-specific",
by using type oid instead of type ssize_t
for row indices / row ids ("rid")
that are stored as type oid in BATs.

(For convenience, these changes are wrapped in CVS tags
 "rid-ssize_t" & "rid-oid".)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


Index: sql_schema.mx
===================================================================
RCS file: /cvsroot/monetdb/sql/src/server/sql_schema.mx,v
retrieving revision 1.177
retrieving revision 1.178
diff -u -d -r1.177 -r1.178
--- sql_schema.mx       1 Aug 2009 17:17:41 -0000       1.177
+++ sql_schema.mx       12 Aug 2009 17:40:48 -0000      1.178
@@ -336,7 +336,7 @@
        sql_column *priv_priv = find_sql_column(privs, "privileges");
        sql_trans *tr = sql->session->tr;
        rids *A;
-       ssize_t r = -1;
+       oid rid = oid_nil;
 
        (void) grantor;
        (void) grantable;
@@ -345,8 +345,8 @@
        A = table_funcs.rids_select(tr, priv_auth, &auth_id, &auth_id, 
priv_priv, &privilege, &privilege, priv_obj, &obj_id, &obj_id, NULL );
 
        /* remove them */
-       for(r = table_funcs.rids_next(A); r>=0; r = table_funcs.rids_next(A)) 
-               table_funcs.table_delete(tr, privs, r); 
+       for(rid = table_funcs.rids_next(A); rid != oid_nil; rid = 
table_funcs.rids_next(A)) 
+               table_funcs.table_delete(tr, privs, rid); 
        table_funcs.rids_destroy(A);
 }
 


------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Monetdb-sql-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-sql-checkins

Reply via email to