Re: [xml] Submitting patches, list or bugzilla?

On Fri, Nov 12, 2010 at 10:12, Arnold Hendriks <a hendriks b-lex nl> wrote:
On 11-11-2010 23:09, Roumen Petrov wrote:

Arnold Hendriks wrote:

Oops. - i dropped the 1

May be libxml configure script don't detect(force) automatically windows
threads for mingw builds.
In this case user could run it with --with-threads=win32.

I have pthreads-win32 and configure libxml using
./configure --without-ftp --without-http --without-python --without-zlib

no specific options - probably it tests for pthreads before looking into
win32 threads ?

The issue 599241 is not correct as with --with-threads=win32 libxml2
builds fine with and without w32-pthread package installed. So I would like
to propose bug 599241 to be marked either as invalid or as feature request.
In first case a new issue could be opened - 'automatic detection of
windows thread for mingw* host'.
About feature request - why not libxml to support both threading models,
windows and posix , for mingw* hosts.

See eg
- a portable application cannot assume pthread_t is castable from/to an
(the first reference I found, but i'm sure it's in the posix specs too - the
issue comes up once in a while on comp.programming.threads)

This is the pthread-win32 definition of pthread_t:

typedef struct {
   void * p;                   /* Pointer to actual object */
   unsigned int x;             /* Extra information - reuse count etc */
} ptw32_handle_t;

typedef ptw32_handle_t pthread_t;

and it's the reason why

tid[i] = (pthread_t) -1;


Setting tid[i] to pthread_self may not be in the right spirit for the tests
I guess, but I don't really know of another way to initialize a threadid.

memset(&tid[i], 0xff, sizeof(tid[i])) ?

May be even replace whole

        for (i = 0; i < num_threads; i++) {
            results[i] = NULL;
            tid[i] = (pthread_t) -1;

        memset(results, 0, sizeof(*results)*num_threads);
        memset(tid, 0xff, sizeof(*tid)*num_threads);

Andrew W. Nosenko <andrew w nosenko gmail com>

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]