Update of /cvsroot/monetdb/sql/src/server
In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv13408/src/server

Modified Files:
        sql_mvc.mx 
Log Message:
fixed race condition


Index: sql_mvc.mx
===================================================================
RCS file: /cvsroot/monetdb/sql/src/server/sql_mvc.mx,v
retrieving revision 1.193
retrieving revision 1.194
diff -u -d -r1.193 -r1.194
--- sql_mvc.mx  9 Dec 2007 13:15:00 -0000       1.193
+++ sql_mvc.mx  23 Dec 2007 21:12:12 -0000      1.194
@@ -396,6 +396,7 @@
                return -1;
        }
 
+       store_lock();
        /* if there is nothing to commit reuse the current transaction */
        if (tr->wtime == 0) {
                if (!chain) 
@@ -404,11 +405,11 @@
                if (mvc_debug)
                        fprintf(stderr, "mvc_commit %s done\n", (name) ? name : 
"");
                m->last = NULL;
+               store_unlock();
                return 0;
        }
 
        /* validation phase */
-       store_lock();
        if (sql_trans_validate(tr)) {
                if ((ok = sql_trans_commit(tr)) != SQL_OK) {
                        char *msg = sql_message("Your disk seems to be full, 
exiting (%s)", GDKerrbuf);


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Monetdb-sql-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-sql-checkins

Reply via email to