[Libreoffice] compile fails: solver/unxlngx6.pro/xml/ure/services.rdb not created

2011-11-12 Thread Luc Castermans
Hi,

Get compile error on testtool:  solver/unxlngx6.pro/xml/ure/services.rdb
is not created.
No matter what I try. Before it was OK.

See:

http://pastebin.com/4cUAnyXF

when I execute the instruction I move one level deeper and get:

http://pastebin.com/F2z0SjNm

Any help, please

-- 
Luc Castermans
mailto:luc.casterm...@gmail.com
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] about daily builds

2011-11-12 Thread Jean-Baptiste Faure

Le 13/11/2011 05:32, Norbert Thiebaud a écrit :

On Wed, Nov 2, 2011 at 7:08 AM, Jean-Baptiste Faure  wrote:

Hi all,

I think it should be interesting to have in the directory of each daily
build a text file giving two informations :
1/ the top commit against which this daily build has been built
2/ the list of autogen.sh options that have been used.

1/ is useful if you want to test a particular fix on a machine where you
can't compile LibreOffice.

2/ is useful to compare a daily build with your own build.



Done: see 
http://dev-builds.libreoffice.org/daily/MacOSX_10.6.7_Intel_no-moz/master/2011-11-13_01.04.10/
there is now a file called *_build.info.txt
that file contains
the generals info relative to the tinderbox
the list of:  on which the build is based
and the output of teh ./autogen.sh command that was used in the build


Great ! Thank you very much

Merci beaucoup Norbert :-)

Best regards.
JBF

--
Seuls des formats ouverts peuvent assurer la pérennité de vos documents.
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] Misrouted bugs.Freedesktop.org report

2011-11-12 Thread Dennis E. Hamilton
Here's an interesting problem.  This report came to dennis.hamilton@ acm.org. 
I am not connected with that bug in any manner.  I am not following it, I did 
not report it, and, of course, it is not assigned to me.

Interesting problem.


 - Dennis E. Hamilton
   tools for document interoperability,  
   dennis.hamil...@acm.org  gsm: +1-206-779-9430  @orcmid



-Original Message-
From: libreoffice-bounces+dennis.hamilton=acm@lists.freedesktop.org 
[mailto:libreoffice-bounces+dennis.hamilton=acm@lists.freedesktop.org] On 
Behalf Of bugzilla-dae...@freedesktop.org
Sent: Saturday, November 12, 2011 16:40
To: lio...@mamane.lu
Subject: [Libreoffice] [Bug 42865] New: MySQL native driver: free() on 
non-heap pointer; in debug mode abort()

https://bugs.freedesktop.org/show_bug.cgi?id=42865

 Bug #: 42865
   Summary: MySQL native driver: free() on non-heap pointer; in
debug mode abort()
Classification: Unclassified
   Product: LibreOffice
   Version: LibO Master
  Platform: All
OS/Version: All
Status: ASSIGNED
  Severity: major
  Priority: medium
 Component: Database
AssignedTo: lio...@mamane.lu
ReportedBy: lio...@mamane.lu
CC: mst...@redhat.com


Open a .odb file that uses the native MySQL driver. Click on "tables" in the
left column to see the list of available tables.

free() is called on a pointer that was not malloc()ed; on a dbgutil build, 
this
leads to an immediate abort() since commit
e0c72547ce57c25db61ec3da6c2f2f2792348c7d, which enables libstdc++ debug mode 
in
dbgutil build.

The root cause is the interplay of how libstdc++ handles empty std::string and
mysqlc.uno.so's version script:

[ ... ]

-- 
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You reported the bug.

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


smime.p7s
Description: S/MIME cryptographic signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] Trouble with autogen on WinXP

2011-11-12 Thread Noel Grandin
I used Mozillabuildsetup.

On Sunday, November 13, 2011, Regina Henschel 
wrote:
> Hi Noel,
>
> Noel Grandin schrieb:
>>
>> I found that I had to install the Mozilla build tools and point autogen
at
>> them to make my build work
>
> What do I need, "MozillaBuildSetup" or "moztools-static" ?
>
> Kind regards
> Regina
> ___
> LibreOffice mailing list
> LibreOffice@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/libreoffice
>
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] about daily builds

2011-11-12 Thread Norbert Thiebaud
On Wed, Nov 2, 2011 at 7:08 AM, Jean-Baptiste Faure  wrote:
> Hi all,
>
> I think it should be interesting to have in the directory of each daily
> build a text file giving two informations :
> 1/ the top commit against which this daily build has been built
> 2/ the list of autogen.sh options that have been used.
>
> 1/ is useful if you want to test a particular fix on a machine where you
> can't compile LibreOffice.
>
> 2/ is useful to compare a daily build with your own build.
>

Done: see 
http://dev-builds.libreoffice.org/daily/MacOSX_10.6.7_Intel_no-moz/master/2011-11-13_01.04.10/
there is now a file called *_build.info.txt
that file contains
the generals info relative to the tinderbox
the list of : on which the build is based
and the output of teh ./autogen.sh command that was used in the build

for example:
---

Build Info
tinderbox: administrator: nthieb...@gmail.com
tinderbox: buildname: MacOSX 10.6.7 Intel no-moz
tinderbox: tree: MASTER
tinderbox: pull time 2011-11-13 01:04:10
tinderbox: git sha1s
core:a7553b213cd7603e9dbac76e92384ca466487915
binfilter:533e3c648db45ba7c7804928a5759e2b60fdb9a2
dictionaries:ca7e6f5cabfeaa82aa4479b8aa1151c26d903993
help:9125509a7c6e65336330b8ac42a293aa77b18ee3

tinderbox: autogen log
running ./configure with '--with-vendor=The Document Foundation'
'--enable-epm' '--enable-binfilter' '--with-java-target-version=1.5'
'--disable-online-update' '--enable-ext-presenter-minimizer'
'--enable-ext-presenter-console' '--enable-ext-pdfimport'
'--enable-ext-wiki-publisher' '--enable-ext-report-builder'
'--enable-ext-scripting-beanshell' '--enable-ext-scripting-javascript'
'--enable-ext-nlpsolver' '--enable-extension-integration'
'--with-max-jobs=8' '--with-num-cpus=6' '--disable-mozilla'
'--enable-werror' '--enable-epm' '--disable-systray'

*
*   Running LibreOffice build configuration.
*


checking build system type... x86_64-apple-darwin10.8.0
checking host system type... x86_64-apple-darwin10.8.0
checking for sed... /usr/bin/sed
[...]


I have pushed the associated changes to contrib/buildbot.

Norbert
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] translating german -> english

2011-11-12 Thread Norbert Thiebaud
On Mon, Nov 7, 2011 at 8:48 AM, Ivan Timofeev  wrote:
> 2011/11/7 Michael Meeks :
>>
>> On Mon, 2011-11-07 at 11:57 +0100, Luc Castermans wrote:
>>> The last thing: I found "patch making"  instructions on the Libo site.
>>> If there are better ones, I like to receive them.
>>
>>        Just doing 'git diff > /tmp/foo.diff' can be good
>
> You can also use 'git diff --color' to see colored diff in terminal.

actually you can set that up once and for all with

git config --global color.diff auto

This will colorized the diff output when the output of the diff is a
terminal (but not colorize it if you pipe or redirect the output to a
file)

See man git-config for all the things that can be tweaked... :-)


Norbert
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] Updating external to new version: mysqlcppconn

2011-11-12 Thread Lionel Elie Mamane
I have in my local working dir an upgrade of the bundled mysqlcppconn
to latest "officially stable" version; it was my first shot at
fdo#42865.

Since I've done the work, I can as well push it; mysqlcppconn's
changelog (bugs fixed) suggests to me it is a good idea.

1) I wanted to first check whether we have a specific policy on when /
   how / why we upgrade bundled externals to newer versions, and if
   that policy tells I should not do it in the current situation.

2) The tarball downloaded from mysql.com unpacks into
   mysql-connector-c++-1.1.0, not mysql-connector-cpp. Am I supposed
   to "repackage" the tarball so that it unpacks into
   mysql-connector-cpp or to change makefile.mk to adapt to the new
   name? (FYI, in my local copy, I have changed makefile.mk to adapt
   to the new name.)

3) I'm also removing from the patch the hunks that do

   // hack around the non-existent ::boost::variant in OOo 3.1 build env

   Since it has been in boost since 2002/2003, so our baseline
   "minimal version supported" of boost should have it!

   Our bundled boost (version 1.44) has boost::variant.

-- 
Lionel
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [Bug 42865] New: MySQL native driver: free() on non-heap pointer; in debug mode abort()

2011-11-12 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=42865

 Bug #: 42865
   Summary: MySQL native driver: free() on non-heap pointer; in
debug mode abort()
Classification: Unclassified
   Product: LibreOffice
   Version: LibO Master
  Platform: All
OS/Version: All
Status: ASSIGNED
  Severity: major
  Priority: medium
 Component: Database
AssignedTo: lio...@mamane.lu
ReportedBy: lio...@mamane.lu
CC: mst...@redhat.com


Open a .odb file that uses the native MySQL driver. Click on "tables" in the
left column to see the list of available tables.

free() is called on a pointer that was not malloc()ed; on a dbgutil build, this
leads to an immediate abort() since commit
e0c72547ce57c25db61ec3da6c2f2f2792348c7d, which enables libstdc++ debug mode in
dbgutil build.

The root cause is the interplay of how libstdc++ handles empty std::string and
mysqlc.uno.so's version script:

libstdc++ does not allocate heap memory for an empty std::string, but makes the
data pointer point to a constant, the symbol _S_empty_rep_storage (initialised
by the linker). The std::string destructor does something along the lines of:

if (the_string.pData != &_S_empty_rep_storage)
   free(the_string.pData)

Normally, the symbol _S_empty_rep_storage is unique global across the whole
process (GNU extension to ELF), so this works well. But the "local: *;" in
mysqlc.uno.so's version link script overrides that and makes the
_S_empty_rep_storage of mysqlc.uno.so different from the _S_empty_rep_storage
of libmysqlcppconn.so. But mysqlc.uno.so's getTables calls libmysqlcppconn.so's
getTables, and gets (among others) empty strings as result (wrapped in a
SQLString); the first occurrence is the name of the catalog of the table (MySQL
does not support catalogs).

When that empty string is destructed within mysqlc.uno.so, the destructor calls
free() on libmysqlcppconn.so's _S_empty_rep_storage, and boum!


The best fix would be to add

{
global:
_ZNSs4_Rep20_S_empty_rep_storageE;
};

to all version link scripts (to get rid of that problem *everywhere*), but that
is not allowed. I filed a request to allow that in GNU ld
(http://sourceware.org/bugzilla/show_bug.cgi?id=13406), but even if we get my
wish, we need another solution until that version of ld can become our
baseline... years away.

Note that exporting that symbol in UDK_3_0_0 (or any other named version) does
*not* work, it needs to be the anonymous version to be compatible with system
DSOs such as mysqlcppconn.so.


Removing the "local: *;" from all link scripts would lead to massive symbol
leak, defeating the purpose of link version scripts. Unless we do something
like *automatically* adding each and every symbol there, except for
"_ZNSs4_Rep20_S_empty_rep_storageE", e.g. with a script that does:

1) Link a first time without .map file
2) use nm/"objdump -T" to get symbols
3) add to .map file every symbol not already mentioned in another section,
except for _ZNSs4_Rep20_S_empty_rep_storageE.
4) Link again with .map file


Anybody got a better idea?


Note that this problem is probably not MySQL-specific, nor Base-specifing; it
will crop up with any external C++ lib that provides us with (potentially
empty) std::string.

-- 
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You reported the bug.

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] [PATCH] Replace command domainname by getdomainname() on Unix

2011-11-12 Thread Lionel Elie Mamane
On Sat, Nov 12, 2011 at 09:00:08PM +0100, Arnaud Versini wrote:

> I have noticed some forks during valgrind check, I think it will be better
> to use functions instead of the unix command. This patch replace the fork
> and exec  domainnanme by a simple call to getdomainname(). It is faster and
> we sould have less message during valgrind and strace
> investigation's.

getdomainname() is not specified by SUS, nor POSIX. However, BSDs have
it since... a long, long time. Google tells me recent versions of
Solaris/SunOS sorta-has it, but not really: it is in -lnsl, but not in
the headers... See
http://old.nabble.com/getdomainname%3A-fix-several-problems-td30324427.html

So I guess we are happy with the portability of that, and I'm committing.

For nitpickers, note that getdomainname does *not* return the DNS
domain, but the NIS domain, which strictly speaking may or may not
coincide. The portable and strictly correct way seems to be to do a
DNS query on the result of gethostname() (gethostbyname or getaddrinfo
with AI_CANONNAME).

-- 
Lionel
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] Trouble with autogen on WinXP

2011-11-12 Thread Regina Henschel

Hi Noel,

Noel Grandin schrieb:

I found that I had to install the Mozilla build tools and point autogen at
them to make my build work


What do I need, "MozillaBuildSetup" or "moztools-static" ?

Kind regards
Regina
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] Trouble with autogen on WinXP

2011-11-12 Thread Noel Grandin
I found that I had to install the Mozilla build tools and point autogen at
them to make my build work

On Saturday, November 12, 2011, Regina Henschel 
wrote:
> Hi all,
>
> this time my try to build fails already in autogen.sh. Up to now I had
used the switches cited below.
> But now
> 1. It does not know "--disable-nss-module"
> 2. It tries to build mozilla, instead of using the prebuild ones
> Breaks here.
>
> Kind regards
> Regina
>
> ./autogen.sh \
>  --with-directx-home="/cygdrive/c/Programme/Microsoft DirectX SDK (March
2009)" \
>  --with-cl-home="/cygdrive/c/Programme/Microsoft Visual Studio 9.0/VC" \
>  --disable-activex \
>  --disable-build-mozilla \
>  --disable-nss-module \
>  --disable-binfilter \
>  --disable-odk \
>  --with-midl-path="/cygdrive/c/Programme/Microsoft
SDKs/Windows/v6.0A/bin" \
>  --with-asm-home="/cygdrive/c/Programme/Microsoft Visual Studio
9.0/VC/bin" \
>  --with-jdk-home="/cygdrive/c/Programme/Java/jdk1.6.0_20" \
>  --with-csc-path="/cygdrive/c/Windows/Microsoft.NET/Framework/v3.5" \
>  --with-ant-home=/ant \
>  --with-mspdb-path="/cygdrive/c/Programme/Microsoft Visual Studio
9.0/Common7/IDE" \
>  --without-junit \
>
> But now
> 1. It does not know "--disable-nss-module"
> 2. It tries to build mozilla, instead of using the prebuild ones
> Breaks here.
>
> ___
> LibreOffice mailing list
> LibreOffice@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/libreoffice
>
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PATCH] Replace command domainname by getdomainname() on Unix

2011-11-12 Thread Arnaud Versini
Hi,

I have noticed some forks during valgrind check, I think it will be better
to use functions instead of the unix command. This patch replace the fork
and exec  domainnanme by a simple call to getdomainname(). It is faster and
we sould have less message during valgrind and strace investigation's.

Best regards

-- 
Arnaud Versini
From 1f15cd04c17af93c7603e8d90137df9a91e86493 Mon Sep 17 00:00:00 2001
From: Arnaud Versini 
Date: Sat, 12 Nov 2011 19:17:03 +0100
Subject: [PATCH] Replace domainname command by getdomainname syscall or
 function

---
 sal/osl/unx/socket.c |   51 -
 1 files changed, 5 insertions(+), 46 deletions(-)

diff --git a/sal/osl/unx/socket.c b/sal/osl/unx/socket.c
index b60fb2d..9c33eaf 100644
--- a/sal/osl/unx/socket.c
+++ b/sal/osl/unx/socket.c
@@ -811,52 +811,11 @@ static struct hostent* _osl_gethostbyname_r (
 
 static sal_Bool  _osl_getDomainName (sal_Char *buffer, sal_Int32 bufsiz)
 {
-sal_Bool result;
-int  p[2];
-
-result = sal_False;
-if (pipe (p) == 0)
-{
-pid_t pid;
-int nStatus;
-
-pid = fork();
-if (pid == 0)
-{
-char *argv[] =
-{
-"/bin/domainname",
-NULL
-};
-
-close (p[0]);
-dup2  (p[1], 1);
-close (p[1]);
-
-execv ("/bin/domainname", argv);
-// arriving here means exec failed
-_exit(-1);
-}
-else if (pid > 0)
-{
-sal_Int32 k = 0, n = bufsiz;
-
-close (p[1]);
-if ((k = read (p[0], buffer, n - 1)) > 0)
-{
-buffer[k] = 0;
-if (buffer[k - 1] == '\n')
-buffer[k - 1] = 0;
-result = sal_True;
-}
-close (p[0]);
-waitpid (pid, &nStatus, 0);
-}
-else
-{
-close (p[0]);
-close (p[1]);
-}
+sal_Bool result = (getdomainname(buffer, bufsiz) == 0);
+if  (!result) {
+OSL_TRACE("osl_getDomainName failed. Errno: %d; %s\n",
+  errno,
+  strerror(errno));
 }
 return (result);
 }
-- 
1.7.5.4

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] cloph's license statement

2011-11-12 Thread Christian Lohmaier
Hi *,

apparently I never sent an official message regarding my contribution,
so here it is for reference/housekeeping:

All past and future contributions by me (be it to the old
OpenOffice.org project or to the LibreOffice project) are under
 LGPLv3+/GPLv3+/MPL until further notice.

ciao
Christian
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] Build fails in moz module

2011-11-12 Thread Anurag Jain
Hi there,

My build is failing in the moz module. I tried building the moz
individually after doing the clean up but could not figure out the problem.

Here is the build log http://pastebin.com/XwrWqgMJ

Please help me figure out what might be causing the problem.

Thanks and regards

-- 
Anurag Jain
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] Trouble with autogen on WinXP

2011-11-12 Thread Regina Henschel

Hi all,

this time my try to build fails already in autogen.sh. Up to now I had 
used the switches cited below.

But now
1. It does not know "--disable-nss-module"
2. It tries to build mozilla, instead of using the prebuild ones
Breaks here.

Kind regards
Regina

./autogen.sh \
 --with-directx-home="/cygdrive/c/Programme/Microsoft DirectX SDK 
(March 2009)" \

 --with-cl-home="/cygdrive/c/Programme/Microsoft Visual Studio 9.0/VC" \
 --disable-activex \
 --disable-build-mozilla \
 --disable-nss-module \
 --disable-binfilter \
 --disable-odk \
 --with-midl-path="/cygdrive/c/Programme/Microsoft 
SDKs/Windows/v6.0A/bin" \
 --with-asm-home="/cygdrive/c/Programme/Microsoft Visual Studio 
9.0/VC/bin" \

 --with-jdk-home="/cygdrive/c/Programme/Java/jdk1.6.0_20" \
 --with-csc-path="/cygdrive/c/Windows/Microsoft.NET/Framework/v3.5" \
 --with-ant-home=/ant \
 --with-mspdb-path="/cygdrive/c/Programme/Microsoft Visual Studio 
9.0/Common7/IDE" \

 --without-junit \

But now
1. It does not know "--disable-nss-module"
2. It tries to build mozilla, instead of using the prebuild ones
Breaks here.

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] [PATCH][PLEASE REVIEW] Remove String::Fill() usage

2011-11-12 Thread Markus Mohrhard
Hello Christina,

2011/11/12 Chr. Rossmanith :
> To add some information: LibO builds fine but I keep getting failed tests in
> the end:
>
> make[1]: ***
> [/Space/LibreOffice_OneGit/core/workdir/unxlngi6.pro/CppunitTest/sc_filters_test.test]
> Fehler 1
>
> It's ./sc where I made modifications and sc_filters_test which fails...
>

This part might be worng:

 if ( bValue )
-aString.AssignAscii( "###" );
-aString.Erase( nLen );
+aString = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "###" ));

Could you paste the exact error message. Normally there should be a
better error message mentioning why the test did fail. Depending on
the place where it fails it should give a relative exact message which
cell is not as expected. Otherwise I'll have a look tomorrow evening.

I think it should fail in sc/qa/unit/data/ods/format.ods. You can
check this file yourself with your build and see what is different to
a 3-4 build.

Regards,
Markus
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] Howto develop an extension with URE?

2011-11-12 Thread Christian Ehrlicher
Am Samstag, 12. November 2011, 12:43:47 schrieb Michael Meeks:
> On Fri, 2011-11-11 at 22:52 +0100, Christian Ehrlicher wrote:
> > > thx - this brings me a step further but can someone explain me how to
> > > create the headers out of the idl-files? They formerly were part of
> > > ure-devel iirc.
> > 
> > Ok, forgive my ignorance :)
> 
>   Not at all ! :-) it is a rather good question.
> 
> > After studiing the examples provided by sdk-doc again I found the
> > cppumaker - command. Now I only have to adjust my cmake script to
> > generate those headers dynamically too.
> 
Ok, next step - is it correct that I don't need a custom rdb anymore? The 
example formerly created an own rdb but is now using offapi.rdb from basis-
link/program
The old rdb creation procedure also used some libs which are not there anymore 
- remotebridge.uno.so and bridgefac.uno.so

Now when I try to use the provided rdb I get an error when I try to load a 
document:
"LoadFromUrl failed: Binary URP bridge disposed during call - 
file:///home/chehrlic/Dokumente/test.odp"
Out of curiosity the documentloader example can load my document and I can't 
find a difference between the example and my code.

I found a bugreport about this message in ubuntu ( 
https://bugs.launchpad.net/ubuntu/+source/libreoffice/+bug/787539 ) but this 
did not help me further.

Is there a wiki about this? All I can find are old instructions ... 

Thx,
Christian
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [REVIEWED 3-4] application crash on exit

2011-11-12 Thread Michael Meeks
Hi Noel,

On Sat, 2011-11-12 at 09:49 +, Noel Power wrote:
> We have an internal bug that happens when closing the application where 
> there is a legacy format document ( e.g. something.sdd ) already open

Thanks for looking at this :-)

> ==23824== Invalid read of size 8
> ==23824==at 0x10C543A0: GtkSalDisplay::EventGuardAcquire() 
> (gtkdata.hxx:83)

So - your fix seems reasonable enough but:

> ==23824==by 0x10C53633: GtkXLib::userEventFn(void*) (gtkdata.cxx:800)
> ==23824==by 0x10C535D4: call_userEventFn (gtkdata.cxx:789)
> ==23824==by 0x13538BD2: g_main_context_dispatch (in 
> /lib64/libglib-2.0.so.0.2800.0)

This processing of events during the GtkXLib destructor is a bit
surprising I suppose. I would be inclined as a belt + braces to add:

if (m_pUserEvent)
{
g_source_destroy (m_pUserEvent);
g_source_unref (m_pUserEvent);
m_pUserEvent = NULL;
}

At the end of ~GtkXLib as well. The hard-coded:

int nMaxEvents = bHandleAllCurrentEvents ? 100 : 1;

in the original code is particularly horrible but ... ;-)

> I had a patch ( that just returned immediately from GtkXLib::userEventFn 
> while GtkXLib was destructing ) However now I see that this doesn't 
> happen on master so after looking there I rewrote the patch be more like 
> ( albeit simpler ) the solution there ( which seems to be part of some 
> bigger rework, for gtk3 ? )

Right - there are some rather substantial changes there. Then again - I
havn't seen my TESTME: warning on shutdown on master so perhaps that
isn't getting exercised much.

> since I know approximately zero about gtk stuff, appreciate wiser heads 
> having a look

Looks fine for the branch for me - any chance you could cherry-pick
it ?

Thanks !

Michael.

-- 
michael.me...@suse.com  <><, Pseudo Engineer, itinerant idiot

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] Howto develop an extension with URE?

2011-11-12 Thread Michael Meeks

On Fri, 2011-11-11 at 22:52 +0100, Christian Ehrlicher wrote:
> > thx - this brings me a step further but can someone explain me how to
> > create the headers out of the idl-files? They formerly were part of
> > ure-devel iirc.
>  
> Ok, forgive my ignorance :)

Not at all ! :-) it is a rather good question.

> After studiing the examples provided by sdk-doc again I found the cppumaker - 
> command. Now I only have to adjust my cmake script to generate those headers 
> dynamically too. 

It seems a nonsense to me to not ship the pre-built C++ headers in the
sdk - particularly if that would make things easier for developers.

Stephan - is there a really good reason for not doing that ? clearly
the easier we make the sdk to use the better, and those headers can be
cut/pasted around / included into the code without problems surely.

ATB,

Michael.

-- 
michael.me...@suse.com  <><, Pseudo Engineer, itinerant idiot

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] iOS and convert to PDF

2011-11-12 Thread Michael Meeks

On Fri, 2011-11-11 at 08:30 -0800, BrianS wrote:
> I might be interested in including some LO source in my app, if that can be
> made to work technically and within License restrictions.

So - in terms of product shipment, you'll want to use the MPL license;
currently that is not possible - but as/when Oracle have finally managed
to get the code under AL2, we'll be applying all our work on top of that
under MPL/LGPLv3+ - that is expected to arrive post LibreOffice 3.5 -
during 3.6 development; I anticipate that done & dusted by the middle of
next year.

>  Since I'm mainly interested in converting documents is it possible
> to isolate that code to a small part of the codebase?

There is a hope that (by munging the code into a single large shared
libary, and link-time-optimising it) that (if we can get the right
constant propagation: "no UI" eg.) much of the bits we don't need will
be auto-evaporated :-) [ you can but hope ]. Failing that, a number of
cuts to the code will have the same effect.

HTH,

Michael.

-- 
michael.me...@suse.com  <><, Pseudo Engineer, itinerant idiot

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] [PUSHED][PATCH] Re: Easy hack regex compile infinite loop ( bug 41738 )

2011-11-12 Thread Noel Grandin
Seems like this is a case where you should be able to find unit
testing in some other open source project, rather than writing them
from scratch.
Mozilla, Apache Harmony, Perl, Webkit, Python, should all have a bunch
of unit testing code for their regular expression features.

In fact, there are a couple of open-source libraries for regex stuff,
I'm sure it would better to simply use the code of one of those other
projects, rather than maintaining our own.
Webkit/Mozilla should have excellent engines inside their JavaScript
modules written in C++ that we could copy.
And they would have seen an enormous amount of testing.

Regards, Noel Grandin


On Fri, Nov 11, 2011 at 18:48,   wrote:
> Hi Eike,
>
> I confirm I contribute this and all future patches for LibreOffice under the 
> LGPLv3+ and MPL 1.1 .
>
>> Yes, there are quite some shortcomings and bugs with that code.
>> I wouldn't invest too much time though, plan is to replace that legacy
>> code entirely with the more suitable ICU regex.
>
> This seems like a nice idea .. is there already a bug/Easy hack for that ?
>
> Thanks !
>
>  - Karl
>
> ___
> LibreOffice mailing list
> LibreOffice@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/libreoffice
>
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PATCH] - avoid odt import crash (fdo#42785)

2011-11-12 Thread Michael Meeks
So,

I'm no writer filter expert; but it seems like there is a rather
incomplete attempt in this code to cope with a NULL mpEditSource - that
I finish off. But of course, perhaps there is a much cleaner / easier
fix elsewhere.

HTH,

Michael.

-- 
michael.me...@suse.com  <><, Pseudo Engineer, itinerant idiot
>From 6ef46645e145f59b83b63b3a14c940725076eac8 Mon Sep 17 00:00:00 2001
From: Michael Meeks 
Date: Sat, 12 Nov 2011 11:15:19 +
Subject: [PATCH] avoid crasher from unusual odt document fdo#42785

---
 editeng/source/uno/unotext.cxx|   34 --
 sw/source/filter/xml/xmltexti.cxx |2 +-
 2 files changed, 21 insertions(+), 15 deletions(-)

diff --git a/editeng/source/uno/unotext.cxx b/editeng/source/uno/unotext.cxx
index ac241d2..5933da3 100644
--- a/editeng/source/uno/unotext.cxx
+++ b/editeng/source/uno/unotext.cxx
@@ -183,6 +183,13 @@ void CheckSelection( struct ESelection& rSel, SvxTextForwarder* pForwarder ) thr
 }
 }
 
+void CheckSelection( struct ESelection& rSel, SvxEditSource *pEdit ) throw()
+{
+if (!pEdit)
+return;
+CheckSelection( rSel, pEdit->GetTextForwarder() );
+}
+
 // 
 // class SvxUnoTextRangeBase
 // 
@@ -275,8 +282,7 @@ void SvxUnoTextRangeBase::SetSelection( const ESelection& rSelection ) throw()
 SolarMutexGuard aGuard;
 
 maSelection = rSelection;
-if (mpEditSource != NULL)
-CheckSelection( maSelection, mpEditSource->GetTextForwarder() );
+CheckSelection( maSelection, mpEditSource );
 }
 
 // Interface XTextRange ( XText )
@@ -291,7 +297,6 @@ uno::Reference< text::XTextRange > SAL_CALL SvxUnoTextRangeBase::getStart(void)
 SvxTextForwarder* pForwarder = mpEditSource ? mpEditSource->GetTextForwarder() : NULL;
 if( pForwarder )
 {
-
 CheckSelection( maSelection, pForwarder );
 
 SvxUnoTextBase* pText = SvxUnoTextBase::getImplementation( getText() );
@@ -406,7 +411,6 @@ void SAL_CALL SvxUnoTextRangeBase::_setPropertyValue( const OUString& PropertyNa
 SvxTextForwarder* pForwarder = mpEditSource ? mpEditSource->GetTextForwarder() : NULL;
 if( pForwarder )
 {
-
 CheckSelection( maSelection, pForwarder );
 
 const SfxItemPropertySimpleEntry* pMap = mpPropSet->getPropertyMapEntry(PropertyName );
@@ -1308,7 +1312,7 @@ uno::Sequence< uno::Any > SAL_CALL SvxUnoTextRangeBase::getPropertyDefaults( con
 // internal
 void SvxUnoTextRangeBase::CollapseToStart(void) throw()
 {
-CheckSelection( maSelection, mpEditSource->GetTextForwarder() );
+CheckSelection( maSelection, mpEditSource );
 
 maSelection.nEndPara = maSelection.nStartPara;
 maSelection.nEndPos  = maSelection.nStartPos;
@@ -1316,7 +1320,7 @@ void SvxUnoTextRangeBase::CollapseToStart(void) throw()
 
 void SvxUnoTextRangeBase::CollapseToEnd(void) throw()
 {
-CheckSelection( maSelection, mpEditSource->GetTextForwarder() );
+CheckSelection( maSelection, mpEditSource );
 
 maSelection.nStartPara = maSelection.nEndPara;
 maSelection.nStartPos  = maSelection.nEndPos;
@@ -1324,7 +1328,7 @@ void SvxUnoTextRangeBase::CollapseToEnd(void) throw()
 
 sal_Bool SvxUnoTextRangeBase::IsCollapsed(void) throw()
 {
-CheckSelection( maSelection, mpEditSource->GetTextForwarder() );
+CheckSelection( maSelection, mpEditSource );
 
 return ( maSelection.nStartPara == maSelection.nEndPara &&
  maSelection.nStartPos  == maSelection.nEndPos );
@@ -1332,7 +1336,7 @@ sal_Bool SvxUnoTextRangeBase::IsCollapsed(void) throw()
 
 sal_Bool SvxUnoTextRangeBase::GoLeft(sal_Int16 nCount, sal_Bool Expand) throw()
 {
-CheckSelection( maSelection, mpEditSource->GetTextForwarder() );
+CheckSelection( maSelection, mpEditSource );
 
 //  #75098# use end position, as in Writer (start is anchor, end is cursor)
 sal_uInt16 nNewPos = maSelection.nEndPos;
@@ -1375,7 +1379,6 @@ sal_Bool SvxUnoTextRangeBase::GoRight(sal_Int16 nCount, sal_Bool Expand)  throw(
 {
 CheckSelection( maSelection, pForwarder );
 
-
 sal_uInt16 nNewPos = maSelection.nEndPos + nCount; //! Overflow???
 sal_uInt16 nNewPar = maSelection.nEndPara;
 
@@ -1419,7 +1422,7 @@ void SvxUnoTextRangeBase::GotoStart(sal_Bool Expand) throw()
 
 void SvxUnoTextRangeBase::GotoEnd(sal_Bool Expand) throw()
 {
-CheckSelection( maSelection, mpEditSource->GetTextForwarder() );
+CheckSelection( maSelection, mpEditSource );
 
 SvxTextForwarder* pForwarder = mpEditSource ? mpEditSource->GetTextForwarder() : NULL;
 if( pForwarder )
@@ -1670,8 +1673,11 @@ void SAL_CALL SvxUnoTextBase::insertString( const uno::Reference< text::XTextRan
 return;
 
 ESelection aSelection;
-::GetSelection( aSelection, GetEditSource()->GetTextForwarder() );
-SetSelection( aSelection );
+if (GetEditSource())
+{
+

[Libreoffice] [PATCH] [REVIEW 3-4] application crash on exit

2011-11-12 Thread Noel Power

(putting patch in subject )

Hi

We have an internal bug that happens when closing the application where 
there is a legacy format document ( e.g. something.sdd ) already open


I get the following trace

==23824== Invalid read of size 8
==23824==at 0x10C543A0: GtkSalDisplay::EventGuardAcquire() 
(gtkdata.hxx:83)

==23824==by 0x10C53633: GtkXLib::userEventFn(void*) (gtkdata.cxx:800)
==23824==by 0x10C535D4: call_userEventFn (gtkdata.cxx:789)
==23824==by 0x13538BD2: g_main_context_dispatch (in 
/lib64/libglib-2.0.so.0.2800.0)

==23824==by 0x135393AF: ??? (in /lib64/libglib-2.0.so.0.2800.0)
==23824==by 0x1353964F: g_main_context_iteration (in 
/lib64/libglib-2.0.so.0.2800.0)

==23824==by 0x10C53861: GtkXLib::Yield(bool, bool) (gtkdata.cxx:868)
==23824==by 0x10C5294A: GtkXLib::~GtkXLib() (gtkdata.cxx:577)
==23824==by 0x10C52A37: GtkXLib::~GtkXLib() (gtkdata.cxx:587)
==23824==by 0x1392F225: X11SalData::DeleteDisplay() (saldata.cxx:293)
==23824==by 0x1392F108: X11SalData::~X11SalData() (saldata.cxx:286)
==23824==by 0x10C53CEB: GtkData::~GtkData() (gtkdata.cxx:1032)
==23824==  Address 0x16002a00 is 576 bytes inside a block of size 2,296 
free'd
==23824==at 0x4C2599C: free (in 
/usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
==23824==by 0x10C50897: GtkSalDisplay::~GtkSalDisplay() 
(gtkdata.cxx:110)

==23824==by 0x1392F1ED: X11SalData::DeleteDisplay() (saldata.cxx:291)
==23824==by 0x1392F108: X11SalData::~X11SalData() (saldata.cxx:286)
==23824==by 0x10C53CEB: GtkData::~GtkData() (gtkdata.cxx:1032)
==23824==by 0x10C53D1D: GtkData::~GtkData() (gtkdata.cxx:1034)
==23824==by 0x139443E5: X11SalInstance::~X11SalInstance() 
(salinst.cxx:141)

==23824==by 0x10C55F5D: GtkInstance::~GtkInstance() (gtkinst.cxx:187)
==23824==by 0x10C55FB1: GtkInstance::~GtkInstance() (gtkinst.cxx:190)
==23824==by 0x99EB564: DestroySalInstance(SalInstance*) 
(salplug.cxx:264)

==23824==by 0x960A5C9: DeInitVCL() (svmain.cxx:566)
==23824==by 0x96094F0: ImplSVMain() (svmain.cxx:198)

I had a patch ( that just returned immediately from GtkXLib::userEventFn 
while GtkXLib was destructing ) However now I see that this doesn't 
happen on master so after looking there I rewrote the patch be more like 
( albeit simpler ) the solution there ( which seems to be part of some 
bigger rework, for gtk3 ? )


attached is the patch, 2 version, one generated ingnoring whitespace ( 
for ease of review ) the other with whitespace for applying


since I know approximately zero about gtk stuff, appreciate wiser heads 
having a look


thanks,
Noel


diff --git a/vcl/unx/gtk/app/gtkdata.cxx b/vcl/unx/gtk/app/gtkdata.cxx
index 6a61098..7c76d6f 100644
--- a/vcl/unx/gtk/app/gtkdata.cxx
+++ b/vcl/unx/gtk/app/gtkdata.cxx
@@ -792,30 +792,36 @@ extern "C"
 
 gboolean GtkXLib::userEventFn(gpointer data)
 {
-gboolean bContinue;
+   
+gboolean bContinue = FALSE;
 GtkXLib *pThis = (GtkXLib *) data;
-SalData *pSalData = GetSalData();
 
-pSalData->m_pInstance->GetYieldMutex()->acquire();
-pThis->m_pGtkSalDisplay->EventGuardAcquire();
+GtkData *pGtkData = static_cast(GetSalData());
+
+pGtkData->m_pInstance->GetYieldMutex()->acquire();
 
-if( !pThis->m_pGtkSalDisplay->HasMoreEvents() )
+if ( pGtkData->GetDisplay() )
 {
-if( pThis->m_pUserEvent )
+pThis->m_pGtkSalDisplay->EventGuardAcquire();
+
+if( !pThis->m_pGtkSalDisplay->HasMoreEvents() )
 {
-g_source_unref (pThis->m_pUserEvent);
-pThis->m_pUserEvent = NULL;
+if( pThis->m_pUserEvent )
+{
+g_source_unref (pThis->m_pUserEvent);
+pThis->m_pUserEvent = NULL;
+}
+bContinue = FALSE;
 }
-bContinue = FALSE;
-}
-else
-bContinue = TRUE;
+else
+bContinue = TRUE;
 
-pThis->m_pGtkSalDisplay->EventGuardRelease();
+pThis->m_pGtkSalDisplay->EventGuardRelease();
 
-pThis->m_pGtkSalDisplay->DispatchInternalEvent();
+pThis->m_pGtkSalDisplay->DispatchInternalEvent();
 
-pSalData->m_pInstance->GetYieldMutex()->release();
+pGtkData->m_pInstance->GetYieldMutex()->release();
+}
 
 return bContinue;
 }


diff --git a/vcl/unx/gtk/app/gtkdata.cxx b/vcl/unx/gtk/app/gtkdata.cxx
index 6a61098..7c76d6f 100644
--- a/vcl/unx/gtk/app/gtkdata.cxx
+++ b/vcl/unx/gtk/app/gtkdata.cxx
@@ -792,11 +792,16 @@ extern "C"
 
 gboolean GtkXLib::userEventFn(gpointer data)
 {
-gboolean bContinue;
+   
+gboolean bContinue = FALSE;
 GtkXLib *pThis = (GtkXLib *) data;
-SalData *pSalData = GetSalData();
 
-pSalData->m_pInstance->GetYieldMutex()->acquire();
+GtkData *pGtkData = static_cast(GetSalData());
+
+pGtkData->m_pInstance->GetYieldMutex()->acquire();
+
+if ( pGtkData->GetDisplay() )
+{
 pThis->m_pGtkSalDisplay->EventGuardAcquire();
 
 if( !pThis->m_pGtkSalDisp

Re: [Libreoffice] [PATCH][PLEASE REVIEW] Remove String::Fill() usage

2011-11-12 Thread Chr. Rossmanith
To add some information: LibO builds fine but I keep getting failed 
tests in the end:


make[1]: *** 
[/Space/LibreOffice_OneGit/core/workdir/unxlngi6.pro/CppunitTest/sc_filters_test.test] 
Fehler 1


It's ./sc where I made modifications and sc_filters_test which fails...

Christina



Am 11.11.2011 23:16, schrieb Chr. Rossmanith:

Hi,

currently I'm removing the Fill() method for strings. Comments are 
very welcome.


Christina


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice