Update of /cvsroot/monetdb/sql/src/backends/monet4
In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv13882/src/backends/monet4
Modified Files:
sql_result.mx
Log Message:
Tyring to fix the code that triggers some of the 120
"conversion from <type1> to <type2>, possible loss of data"
warnings with the Microsoft compiler on Windows (cf.,
http://monetdb.cwi.nl/testing/projects/monetdb/Current/sql/.Mic.32.32.d.1-Windows5.1..2008.08.29_00-09-02/make.out.html
):
use the correct type: strlen returns size_t, NOT int
(Check the effect tomorrow at
http://monetdb.cwi.nl/testing/projects/monetdb/Current/sql/.Mic.32.32.d.1-Windows5.1/make.out.html
and
http://monetdb.cwi.nl/testing/projects/monetdb/Current/sql/.Mic.64.64.d.1-Windows5.2/make.out.html
)
Most of the remaining warnings are due to the fact that
member "ival" of struct "symbdata" in src/server/sql_symbol.mx
is defined as "lng" but often used as / assigned to "int"
(without cast or overflow check).
I will try to find a proper solution for this together with
Niels and/or Sjoerd...
U sql_result.mx
Index: sql_result.mx
===================================================================
RCS file: /cvsroot/monetdb/sql/src/backends/monet4/sql_result.mx,v
retrieving revision 1.84
retrieving revision 1.85
diff -u -d -r1.84 -r1.85
--- sql_result.mx 25 Aug 2008 13:36:15 -0000 1.84
+++ sql_result.mx 31 Aug 2008 21:54:29 -0000 1.85
@@ -616,8 +616,8 @@
int l = 0;
if (!p || ATOMcmp(mtype, ATOMnilptr(mtype), p) == 0) {
- l = strlen(ns);
- ok = (stream_write(s, ns, l, 1) == 1);
+ size_t ll = strlen(ns);
+ ok = (stream_write(s, ns, ll, 1) == 1);
} else if (eclass == EC_DEC) {
l = dec_tostr((void *) (ptrdiff_t) sc, buf, len,
mtype, p);
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Monetdb-sql-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-sql-checkins