Please take our Survey
logo       

Choosing A Webhost:
A web hosting service is a type of Internet hosting service that allows individuals and organizations to provide their own website accessible via the World Wide Web. Web hosts are companies that provide space on a server they own for use by their clients as well as providing Internet connectivity, typically in a data center. Web hosts can also provide data center space and connectivity to the Internet for servers they do not own to be located in their data center, called colocation. more...

Re: send_with_block_and_reply fail: msg#00031

freedesktop.dbus

Subject: Re: send_with_block_and_reply fail

This message is in MIME format.
Quoting Olivier Andrieu
<oliv__a-Rn4VEauK+AKRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx>:

> Hi,
>
> Johan FISCHER [Wed, 16 Jun 2004]:
> > So, it seems the client receive a reply message serial 32, insert
> > it in the incoming queue, delete it (no filter installed) and then
> > the dbus_send_with_rpely_and_block start listening for the reply.
> >
> > Any idea ?
>
> Could you try this patch ?
>
> --
> Olivier

Hi,

Humm after trying a lot of different combination, the problem may be in the
thread functions.

Ok, here are the comments:
I join two files (server.c and client.c) which use the glib binding. Like they
are in the attachement, they work fine.

In server.c, if I uncomment these two lines :
//g_thread_init (NULL);
//dbus_g_thread_init ();

The server exit with a segmentation fault after 5 loop.

In client.c, if I uncomment these two lines :
//loop = g_main_loop_new (NULL, FALSE);
//g_main_loop_run (loop);
I got this error:
32373: assertion failed "!connection->io_path_acquired" file
"dbus-connection.c"
line 733
Aborted

My project looks a lot like the client as I want to be able to listen
to server
signals at the same time (or not entirely) at sending request to the server.
Is there a problem in the source code ?

So I think because of the gloop, the send_with_reply_and_block has to wait to
get the listen state for the loop and miss the message which doesn't stay in
the queue also because of the loop.

Thx for your help.

Johan.

----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.

----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.

Attachment: binxgRdWsRGXW.bin
Description: PGP Public Key

Attachment: client.c
Description: Text Data

Attachment: server.c
Description: Text Data

Attachment: bineqW7ntLjmG.bin
Description: PGP Public Key



<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe

Navigation

Home | advertise | OSDir is an inevitable website. super tiny logo