Date: prev next · Thread: first prev next last
2011 Archives by date, by thread · List index


Hi

Oups sorry yes of course I'm wrong

Sorry for the bug

Best regards

2011/12/7 Stephan Bergmann <sbergman@redhat.com>

-#if defined(LINUX)
-/* The linux kernel thread implemention, always return the pid of the
-   thread subprocess and not of the main process. So we save the main
-   pid at startup
+#if defined(LINUX) && defined (__GLIBC__) && __GLIBC__ == 2 ||
__GLIBC_MINOR__ < 4


The above looks broken, given that && binds tighter than ||.  From the
comments, I gather that what actually should be checked is that
__GLIBC__.__GLIBC_MINOR__ < 2.4, right?  So, since we would not care about
glibc 1, anyway, the || should be replaced with a && I think.

Stephan

 +/* The linux kernel 2.4 getpid implemention always return the pid of the
+   thread subprocess and not of the main process, the NPTL implementation
+   with a Linux kernel 2.6 kernel return the pid. So when possibly
+   their is the wrong implementation of getpid, we save the pid at
startup.
   FIXME: when our Linux base-line is above:
-        + Linux kernel version 2.6.18 or higher; -> clone() for NTPL
-        + glibc2 version 2.5 or higher; -> NPTL
+        + Linux kernel version 2.6 or higher; -> clone() for NTPL
+        + glibc2 version 2.4 or higher; -> No longer LinuxThreads, only
NPTL
   Then we get a working getpid() and can remove this hack.
+   FIXME: getppid is also wrong in this situation
 */



______________________________**_________________
LibreOffice mailing list
LibreOffice@lists.freedesktop.**org <LibreOffice@lists.freedesktop.org>
http://lists.freedesktop.org/**mailman/listinfo/libreoffice<http://lists.freedesktop.org/mailman/listinfo/libreoffice>




-- 
Arnaud Versini

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.