include/tools/solar.h |   10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

New commits:
commit 029fa6477bfed71881c3287799f5bdffd3285f92
Author: Matteo Casalin <matteo.casa...@yahoo.com>
Date:   Wed Jul 22 23:22:56 2015 +0200

    solar.h: avoid some Wconversion warnings
    
    Change-Id: Id41bd4e759dea72b37db5f329e29ff5c18c75a66
    Reviewed-on: https://gerrit.libreoffice.org/17306
    Tested-by: Jenkins <c...@libreoffice.org>
    Reviewed-by: Eike Rathke <er...@redhat.com>
    Tested-by: Eike Rathke <er...@redhat.com>

diff --git a/include/tools/solar.h b/include/tools/solar.h
index c8d83ac..717ad78 100644
--- a/include/tools/solar.h
+++ b/include/tools/solar.h
@@ -47,12 +47,14 @@ typedef sal_uInt8   SVBT64[8];
 
 #ifdef __cplusplus
 
-inline sal_uInt16 SVBT16ToShort( const SVBT16 p ) { return (sal_uInt16)p[0]
-                                                   + ((sal_uInt16)p[1] <<  8); 
}
-inline sal_uInt32 SVBT32ToUInt32 ( const SVBT32 p ) { return (sal_uInt32)p[0]
+inline sal_uInt16 SVBT16ToShort( const SVBT16 p ) { return 
static_cast<sal_uInt16>
+                                                     ((sal_uInt16)p[0]
+                                                   + ((sal_uInt16)p[1] <<  
8)); }
+inline sal_uInt32 SVBT32ToUInt32 ( const SVBT32 p ) { return 
static_cast<sal_uInt32>
+                                                     ((sal_uInt32)p[0]
                                                    + ((sal_uInt32)p[1] <<  8)
                                                    + ((sal_uInt32)p[2] << 16)
-                                                   + ((sal_uInt32)p[3] << 24); 
}
+                                                   + ((sal_uInt32)p[3] << 
24)); }
 #if defined OSL_LITENDIAN
 inline double   SVBT64ToDouble( const SVBT64 p ) { double n;
                                                     
reinterpret_cast<sal_uInt8*>(&n)[0] = p[0];
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to