Changeset: 12d6f4fa98e7 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=12d6f4fa98e7
Modified Files:
        monetdb5/mal/mal_session.c
Branch: default
Log Message:

Don't send exception decoration to client, just like before.
This way we don't have to change all clients.


diffs (24 lines):

diff --git a/monetdb5/mal/mal_session.c b/monetdb5/mal/mal_session.c
--- a/monetdb5/mal/mal_session.c
+++ b/monetdb5/mal/mal_session.c
@@ -646,8 +646,18 @@ MALcommentsOnly(MalBlkPtr mb)
 str
 MALcallback(Client c, str msg)
 {
-       if (msg){
-               mnstr_printf(c->fdout,"!%s%s", msg, (msg[strlen(msg)-1] == 
'\n'? "":"\n"));
+       if (msg) {
+               /* don't print exception decoration, just the message */
+               char *n = NULL;
+               char *o = msg;
+               while ((n = strchr(o, '\n')) != NULL) {
+                       *n = '\0';
+                       mnstr_printf(c->fdout, "!%s\n", getExceptionMessage(o));
+                       *n++ = '\n';
+                       o = n;
+               }
+               if (*o != 0)
+                       mnstr_printf(c->fdout, "!%s\n", getExceptionMessage(o));
                freeException(msg);
        }
        return MAL_SUCCEED;
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to