| View previous topic :: View next topic |
| Author |
Message |
mase
Joined: 31 May 2009 Posts: 16
|
Posted: Fri Jun 05, 2009 9:58 pm Post subject: Problem with libshout programming |
|
|
Hi!
I am writing a source client using libshout.
I have created a separate thread that fills the buffer (4096bytes),
and sends it to the server in a loop.
Now I have built in the possibility to pause this thread.
If I pause the thread for 5 seconds, everything runs ok. If I pause for
about 10 seconds, the program exits without any error, when the thread
continues.
I debugged it with gdb. After continue one bufferblock is filled and sent to
the icecast server. Then the buffer gets refilled. If it reaches now the
function to send the buffer again , gdb gives this message:
Signal SIGPIPE (Broken pipe)
What does that mean, and what can be the cause for this? |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Fri Jun 05, 2009 10:52 pm Post subject: |
|
|
I would suspect that icecast drops the connection because no data has come down the socket for many seconds. If you really want it to stay open for long periods of inactivity then increase the timeout in icecast
karl. |
|
| Back to top |
|
 |
mase
Joined: 31 May 2009 Posts: 16
|
Posted: Fri Jun 05, 2009 11:19 pm Post subject: |
|
|
Thanks!
Yes, you're right. It seems to be a timeout. But how can I detect this?
int shout_get_connected(shout_t *self); does not give a lost connection. |
|
| Back to top |
|
 |
|