[Libreoffice-commits] core.git: 3 commits - configure.ac jvmfwk/plugins mysqlcppconn/config.h
Michael Stahl
mstahl at redhat.com
Sun Jun 2 11:42:01 PDT 2013
configure.ac | 2 +-
jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx | 18 +++++++-----------
mysqlcppconn/config.h | 4 +++-
3 files changed, 11 insertions(+), 13 deletions(-)
New commits:
commit 1ff01d207d90685cb897f518c2a688b5ef33358e
Author: Michael Stahl <mstahl at redhat.com>
Date: Sun Jun 2 16:37:40 2013 +0200
jvmfwk: de-Pascalize do_msvcr71_magic
The uninitialized Module variable causes the smoketest to fail when
built with MSVC 2012 (assinging to it raises some weird exception).
Change-Id: I77b3b591a94f4dfbb373938e3787f75e6a8e09c5
diff --git a/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx b/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx
index f9528b0..981b827 100644
--- a/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx
+++ b/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx
@@ -482,20 +482,15 @@ static void load_msvcr71(LPCWSTR jvm_dll)
// and just let the implicit loading try to take care of it.
static void do_msvcr71_magic(rtl_uString *jvm_dll)
{
- FILE *f;
- rtl_uString* Module;
- oslFileError nError;
+ rtl_uString* Module(0);
struct stat st;
- PIMAGE_DOS_HEADER dos_hdr;
- IMAGE_NT_HEADERS *nt_hdr;
- IMAGE_IMPORT_DESCRIPTOR *imports;
- nError = osl_getSystemPathFromFileURL(jvm_dll, &Module);
+ oslFileError nError = osl_getSystemPathFromFileURL(jvm_dll, &Module);
if ( osl_File_E_None != nError )
rtl_uString_assign(&Module, jvm_dll);
- f = _wfopen(reinterpret_cast<LPCWSTR>(Module->buffer), L"rb");
+ FILE *f = _wfopen(reinterpret_cast<LPCWSTR>(Module->buffer), L"rb");
if (fstat(fileno(f), &st) == -1)
{
@@ -503,7 +498,7 @@ static void do_msvcr71_magic(rtl_uString *jvm_dll)
return;
}
- dos_hdr = (PIMAGE_DOS_HEADER) malloc(st.st_size);
+ PIMAGE_DOS_HEADER dos_hdr = (PIMAGE_DOS_HEADER) malloc(st.st_size);
if (fread(dos_hdr, st.st_size, 1, f) != 1 ||
memcmp(dos_hdr, "MZ", 2) != 0 ||
@@ -517,9 +512,10 @@ static void do_msvcr71_magic(rtl_uString *jvm_dll)
fclose(f);
- nt_hdr = (IMAGE_NT_HEADERS *) ((char *)dos_hdr + dos_hdr->e_lfanew);
+ IMAGE_NT_HEADERS *nt_hdr = (IMAGE_NT_HEADERS *) ((char *)dos_hdr + dos_hdr->e_lfanew);
- imports = (IMAGE_IMPORT_DESCRIPTOR *) ((char *) dos_hdr + nt_hdr->OptionalHeader.DataDirectory[IMAGE_DIRECTORY_ENTRY_IMPORT].VirtualAddress);
+ IMAGE_IMPORT_DESCRIPTOR *imports =
+ (IMAGE_IMPORT_DESCRIPTOR *) ((char *) dos_hdr + nt_hdr->OptionalHeader.DataDirectory[IMAGE_DIRECTORY_ENTRY_IMPORT].VirtualAddress);
while (imports <= (IMAGE_IMPORT_DESCRIPTOR *) ((char *) dos_hdr + st.st_size - sizeof (IMAGE_IMPORT_DESCRIPTOR)) &&
imports->Name != 0 &&
commit 23583553d1a9951eaa33dfb598606cdf55d3f01a
Author: Michael Stahl <mstahl at redhat.com>
Date: Sun Jun 2 13:26:30 2013 +0200
mysqlcppconn: MSVC 2010 finally has grown a stdint.h
Change-Id: I5b8d948aad94ba492075245c18c8ed781baa469e
diff --git a/mysqlcppconn/config.h b/mysqlcppconn/config.h
index 19cf389..e30a0cb 100644
--- a/mysqlcppconn/config.h
+++ b/mysqlcppconn/config.h
@@ -5,10 +5,12 @@
#define HAVE_FUNCTION_STRTOL 1
#define HAVE_FUNCTION_STRTOULL 1
-#if defined(MACOSX) || defined(SOLARIS) || defined(LINUX)
+#if defined(MACOSX) || defined(SOLARIS) || defined(LINUX) || (defined _MSC_VER && _MSC_VER >= 1600)
#define HAVE_STDINT_H
+#ifndef _MSC_VER
#define HAVE_INTTYPES_H
#endif
+#endif
#ifdef HAVE_STDINT_H
#include <stdint.h>
commit 58873656afdafd8a6c5b038e1a15e5c022f3558b
Author: Michael Stahl <mstahl at redhat.com>
Date: Sun Jun 2 13:24:23 2013 +0200
configure: fix warning about missing test parameter
Change-Id: I9478a0c3703f5c9c6341f60db13eade195d074b4
diff --git a/configure.ac b/configure.ac
index 54ef307..6bf8c1f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -7397,7 +7397,7 @@ no|disable)
AC_MSG_RESULT([none])
;;
""|yes|auto)
- if test "$DISABLE_SCRIPTING" = TRUE -a -n $PYTHON_FOR_BUILD; then
+ if test "$DISABLE_SCRIPTING" = TRUE -a -n "$PYTHON_FOR_BUILD"; then
AC_MSG_RESULT([no, overridden by --disable-scripting])
enable_python=no
elif test $build_os = cygwin; then
More information about the Libreoffice-commits
mailing list