Changeset: 6c1781e74652 for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=6c1781e74652
Modified Files:
        monetdb5/mal/mal_interpreter.c
        sql/test/BugTracker-2014/Tests/queueError.Bug-3604.sql
        sql/test/BugTracker-2014/Tests/queueError.Bug-3604.stable.err
        sql/test/BugTracker-2014/Tests/queueError.Bug-3604.stable.out
Branch: Oct2014
Log Message:

Properly fix bug 3604: only call runtimeProfileFinish in case of error.
See changeset 8455d3abe150.


diffs (84 lines):

diff --git a/monetdb5/mal/mal_interpreter.c b/monetdb5/mal/mal_interpreter.c
--- a/monetdb5/mal/mal_interpreter.c
+++ b/monetdb5/mal/mal_interpreter.c
@@ -760,7 +760,8 @@ str runMALsequence(Client cntxt, MalBlkP
                        /* monitoring information should reflect the input 
arguments,
                           which may be removed by garbage collection  */
                        runtimeProfileExit(cntxt, mb, stk, pci, 
&runtimeProfile);
-                       runtimeProfileFinish(cntxt, mb);
+                       if (ret != MAL_SUCCEED)
+                               runtimeProfileFinish(cntxt, mb);
                        /* check for strong debugging after each MAL statement 
*/
                        if ( pci->token != FACcall && ret== MAL_SUCCEED) {
                                if (GDKdebug & (CHECKMASK|PROPMASK) && 
exceptionVar < 0) {
diff --git a/sql/test/BugTracker-2014/Tests/queueError.Bug-3604.sql 
b/sql/test/BugTracker-2014/Tests/queueError.Bug-3604.sql
--- a/sql/test/BugTracker-2014/Tests/queueError.Bug-3604.sql
+++ b/sql/test/BugTracker-2014/Tests/queueError.Bug-3604.sql
@@ -1,5 +1,5 @@
-select qtag,user,status,query from sys.queue();
+select user,status,query from sys.queue();
 drop table xyz;
-select qtag,user,status,query from sys.queue();
+select user,status,query from sys.queue();
 drop table yz;
-select qtag,user,status,query from sys.queue();
+select user,status,query from sys.queue();
diff --git a/sql/test/BugTracker-2014/Tests/queueError.Bug-3604.stable.err 
b/sql/test/BugTracker-2014/Tests/queueError.Bug-3604.stable.err
--- a/sql/test/BugTracker-2014/Tests/queueError.Bug-3604.stable.err
+++ b/sql/test/BugTracker-2014/Tests/queueError.Bug-3604.stable.err
@@ -27,10 +27,10 @@ stderr of test 'queueError.Bug-3604` in 
 # cmdline opt  gdk_debug = 536870922
 
 
-MAPI  = (monetdb) /var/tmp/mtest-31705/.s.monetdb.38458
+MAPI  = (monetdb) /var/tmp/mtest-8635/.s.monetdb.30394
 QUERY = drop table xyz;
 ERROR = !DROP TABLE: no such table 'xyz'
-MAPI  = (monetdb) /var/tmp/mtest-31705/.s.monetdb.38458
+MAPI  = (monetdb) /var/tmp/mtest-8635/.s.monetdb.30394
 QUERY = drop table yz;
 ERROR = !DROP TABLE: no such table 'yz'
 
diff --git a/sql/test/BugTracker-2014/Tests/queueError.Bug-3604.stable.out 
b/sql/test/BugTracker-2014/Tests/queueError.Bug-3604.stable.out
--- a/sql/test/BugTracker-2014/Tests/queueError.Bug-3604.stable.out
+++ b/sql/test/BugTracker-2014/Tests/queueError.Bug-3604.stable.out
@@ -53,21 +53,24 @@ Ready.
 # 11:43:52 >  "mclient" "-lsql" "-ftest" "-Eutf-8" "-i" "-e" 
"--host=/var/tmp/mtest-3599" "--port=35114"
 # 11:43:52 >  
 
-#select qtag,user,status,query from sys.queue();
-% .L,  .L1,    .L1,    .L1 # table_name
-% qtag,        L1,     status, query # name
-% bigint,      varchar,        clob,   clob # type
-% 1,   0,      0,      0 # length
-#select qtag,user,status,query from sys.queue();
-% .L,  .L1,    .L1,    .L1 # table_name
-% qtag,        L1,     status, query # name
-% bigint,      varchar,        clob,   clob # type
-% 1,   0,      0,      0 # length
-#select qtag,user,status,query from sys.queue();
-% .L,  .L1,    .L1,    .L1 # table_name
-% qtag,        L1,     status, query # name
-% bigint,      varchar,        clob,   clob # type
-% 1,   0,      0,      0 # length
+#select user,status,query from sys.queue();
+% .L1, .L1,    .L1 # table_name
+% L1,  status, query # name
+% varchar,     clob,   clob # type
+% 7,   7,      42 # length
+[ "monetdb",   "running",      "select user,status,query from sys.queue();"    
]
+#select user,status,query from sys.queue();
+% .L1, .L1,    .L1 # table_name
+% L1,  status, query # name
+% varchar,     clob,   clob # type
+% 7,   7,      42 # length
+[ "monetdb",   "running",      "select user,status,query from sys.queue();"    
]
+#select user,status,query from sys.queue();
+% .L1, .L1,    .L1 # table_name
+% L1,  status, query # name
+% varchar,     clob,   clob # type
+% 7,   7,      42 # length
+[ "monetdb",   "running",      "select user,status,query from sys.queue();"    
]
 
 # 11:43:52 >  
 # 11:43:52 >  "Done."
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to