close fixes, obvious bug in webserver.c
This commit is contained in:
parent
9f5eabdabf
commit
a9e2d3a1b5
|
@ -149,7 +149,9 @@ void daap_handler(WS_CONNINFO *pwsc) {
|
||||||
/* This we should put in a quirks file or something, but here might
|
/* This we should put in a quirks file or something, but here might
|
||||||
* be a decent workaround for various failures on different clients */
|
* be a decent workaround for various failures on different clients */
|
||||||
pwsc->close=0;
|
pwsc->close=0;
|
||||||
|
if(ws_testrequestheader(pwsc,"Connection","Close")) {
|
||||||
|
pwsc->close = 1;
|
||||||
|
}
|
||||||
|
|
||||||
if(ws_getvar(pwsc,"session-id"))
|
if(ws_getvar(pwsc,"session-id"))
|
||||||
pqi->session_id = atoi(ws_getvar(pwsc,"session-id"));
|
pqi->session_id = atoi(ws_getvar(pwsc,"session-id"));
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* $Id$
|
* $id: webserver.c,v 1.39 2005/11/15 06:43:31 rpedde Exp $
|
||||||
* Webserver library
|
* Webserver library
|
||||||
*
|
*
|
||||||
* Copyright (C) 2003 Ron Pedde (ron@pedde.com)
|
* Copyright (C) 2003 Ron Pedde (ron@pedde.com)
|
||||||
|
@ -485,7 +485,6 @@ void *ws_mainthread(void *arg) {
|
||||||
void ws_close(WS_CONNINFO *pwsc) {
|
void ws_close(WS_CONNINFO *pwsc) {
|
||||||
WS_PRIVATE *pwsp = (WS_PRIVATE *)pwsc->pwsp;
|
WS_PRIVATE *pwsp = (WS_PRIVATE *)pwsc->pwsp;
|
||||||
|
|
||||||
|
|
||||||
DPRINTF(E_SPAM,L_WS,"Entering ws_close\n");
|
DPRINTF(E_SPAM,L_WS,"Entering ws_close\n");
|
||||||
|
|
||||||
DPRINTF(E_DBG,L_WS,"Thread %d: Terminating\n",pwsc->threadno);
|
DPRINTF(E_DBG,L_WS,"Thread %d: Terminating\n",pwsc->threadno);
|
||||||
|
@ -1557,6 +1556,9 @@ void ws_unlock_local_storage(WS_CONNINFO *pwsc) {
|
||||||
* set the local storage pointer (and callback)
|
* set the local storage pointer (and callback)
|
||||||
*/
|
*/
|
||||||
void ws_set_local_storage(WS_CONNINFO *pwsc, void *ptr, void (*callback)(void *)) {
|
void ws_set_local_storage(WS_CONNINFO *pwsc, void *ptr, void (*callback)(void *)) {
|
||||||
|
if(!pwsc)
|
||||||
|
return;
|
||||||
|
|
||||||
if(pwsc->local_storage) {
|
if(pwsc->local_storage) {
|
||||||
if(pwsc->storage_callback) {
|
if(pwsc->storage_callback) {
|
||||||
pwsc->storage_callback(pwsc->local_storage);
|
pwsc->storage_callback(pwsc->local_storage);
|
||||||
|
|
Loading…
Reference in New Issue