diff options
author | Michael Krelin <hacker@klever.net> | 2007-07-16 00:17:19 +0000 |
---|---|---|
committer | Michael Krelin <hacker@klever.net> | 2007-07-16 00:17:19 +0000 |
commit | 484e65a218aec49236471eca60da314a1172584e (patch) | |
tree | df571ec0d425cdb3451e4b463fa62c965e1c476e /packages/libopieobex | |
parent | b5da5388d3816b879cb70a53d70a74ae0285087e (diff) |
libopieobex0: properly fix issues at hand
Diffstat (limited to 'packages/libopieobex')
-rw-r--r-- | packages/libopieobex/files/obex-fixes.patch | 26 | ||||
-rw-r--r-- | packages/libopieobex/libopieobex0_cvs.bb | 2 |
2 files changed, 18 insertions, 10 deletions
diff --git a/packages/libopieobex/files/obex-fixes.patch b/packages/libopieobex/files/obex-fixes.patch index 19555594cb..184f29846e 100644 --- a/packages/libopieobex/files/obex-fixes.patch +++ b/packages/libopieobex/files/obex-fixes.patch @@ -20,10 +20,10 @@ index 05118ab..2372d12 100644 DEFINES += BLUETOOTH } diff --git a/obexserver.cpp b/obexserver.cpp -index f1fb205..786e9f7 100644 +index f1fb205..a98c64f 100644 --- a/obexserver.cpp +++ b/obexserver.cpp -@@ -207,7 +207,18 @@ static void obex_conn_event (obex_t *handle, obex_object_t *object, +@@ -207,7 +207,19 @@ static void obex_conn_event (obex_t *handle, obex_object_t *object, /* Comes when a server-request has been received. */ handle_request (handle, object, event, obex_cmd); break; @@ -35,6 +35,7 @@ index f1fb205..786e9f7 100644 + break; + case OBEX_CMD_DISCONNECT: + OBEX_TransportDisconnect(handle); ++ _exit(0); + break; + default: + break; @@ -43,15 +44,20 @@ index f1fb205..786e9f7 100644 case OBEX_EV_LINKERR: break; } -@@ -424,20 +435,12 @@ bool ObexServer::start(RunMode runmode, Communication comm) +@@ -423,21 +435,15 @@ bool ObexServer::start(RunMode runmode, Communication comm) + fcntl( fd[ 1 ], F_SETFD, FD_CLOEXEC ); if (initObex() == 0) { ++ if ( fd[ 1 ] ) { ++ ::close(fd[1]); ++ fd[1] = 0; ++ } do { - int result; //Connection result - if ( fd[ 1 ] ) { - ::close(fd[1]); - fd[1] = 0; - } +- if ( fd[ 1 ] ) { +- ::close(fd[1]); +- fd[1] = 0; +- } - if ((result = OBEX_HandleInput(m_obex, 60)) < 0) { - if (errno != ECONNRESET) { - printf("OBEX_HandleInput error %d\n", errno); @@ -61,8 +67,10 @@ index f1fb205..786e9f7 100644 - else - _exit(0); - } -+ if (OBEX_HandleInput(m_obex, 10) < 0) -+ _exit(0); ++ if (OBEX_HandleInput(m_obex, 60) < 0) { ++ fprintf(stderr,"failed to OBEX_HandleInput(), errno=%d\n"); ++ _exit(errno?errno:-1); ++ } } while(1); } char resultByte = 1; diff --git a/packages/libopieobex/libopieobex0_cvs.bb b/packages/libopieobex/libopieobex0_cvs.bb index 79b7a6b803..fe6216155c 100644 --- a/packages/libopieobex/libopieobex0_cvs.bb +++ b/packages/libopieobex/libopieobex0_cvs.bb @@ -1,6 +1,6 @@ require libopieobex0.inc PV = "${OPIE_CVS_PV}" -PR = "r3" +PR = "r5" SRC_URI = "${HANDHELDS_CVS};module=opie/core/obex \ ${HANDHELDS_CVS};module=opie/pics \ |