]> granicus.if.org Git - postgresql/commitdiff
Quiet a few MSC compiler warnings.
authorAndrew Dunstan <andrew@dunslane.net>
Sun, 7 Oct 2012 21:31:10 +0000 (17:31 -0400)
committerAndrew Dunstan <andrew@dunslane.net>
Sun, 7 Oct 2012 21:31:10 +0000 (17:31 -0400)
src/backend/catalog/objectaddress.c
src/backend/optimizer/path/costsize.c
src/backend/utils/adt/array_selfuncs.c
src/interfaces/ecpg/ecpglib/typename.c

index b3b2bc688ec0c5c4a11f8572c876e0950ab486c5..d7a726c2c4ac9f103d50113e39d15aac6e1ed7c4 100644 (file)
@@ -1360,4 +1360,6 @@ get_object_property_data(Oid class_id)
 
        ereport(ERROR,
                        (errmsg_internal("unrecognized class id: %u", class_id)));
+
+       return NULL; /* keep MSC compiler happy */
 }
index 3e99b230f5be482389405b0f7adcd7820d41616e..544b63f149e1bb14a902a6bae892f3dad2a2a74d 100644 (file)
@@ -68,6 +68,9 @@
 
 #include "postgres.h"
 
+#ifdef _MSCVER
+#include <float.h> /* for _isnan */
+#endif
 #include <math.h>
 
 #include "access/htup_details.h"
index 622d6d13ceeba7e0ac921ea41ece85bc615fe247..03f703c2deea773a849bb0b4fee642293469a48f 100644 (file)
@@ -571,7 +571,7 @@ mcelem_array_contain_overlap_selec(Datum *mcelem, int nmcelem,
        else
        {
                /* Without statistics make some default assumptions */
-               minfreq = 2 * DEFAULT_CONTAIN_SEL;
+               minfreq = 2 * (float4) DEFAULT_CONTAIN_SEL;
        }
 
        /* Decide whether it is faster to use binary search or not. */
index 98b81894f35683c5ca20313825110bffee7683ce..d0081812f3d992aab6564fc0eea25ca3f9d7a32b 100644 (file)
@@ -65,6 +65,7 @@ ecpg_type_name(enum ECPGttype typ)
                default:
                        abort();
        }
+       return ""; /* keep MSC compiler happy */
 }
 
 int