X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=src%2Fsession.c;h=9504fdbe71835e4eca7c007b6fa8282bc1bec2cf;hb=520bbafb30ce49b94b7825ff553d8cb5bda6d612;hp=9569b46c1cf51721aef24b973f3c14cfc493b0f9;hpb=ca208671cc79bbc05c574df788035878e5d39382;p=src%2Fapp-framework-binder.git diff --git a/src/session.c b/src/session.c index 9569b46c..9504fdbe 100644 --- a/src/session.c +++ b/src/session.c @@ -31,6 +31,7 @@ #include #include "afb-apis.h" +#include "session.h" // Session UUID are store in a simple array [for 10 sessions this should be enough] static struct { @@ -169,7 +170,7 @@ void ctxStoreGarbage (const int timeout) } // This function will return exiting client context or newly created client context -AFB_clientCtx *ctxClientGet (AFB_request *request, int apiidx) +AFB_clientCtx *ctxClientGet (AFB_request *request) { AFB_clientCtx *clientCtx=NULL; const char *uuid; @@ -201,8 +202,6 @@ AFB_clientCtx *ctxClientGet (AFB_request *request, int apiidx) ctxStoreDel (clientCtx); clientCtx = NULL; } else { - request->context = clientCtx->contexts[apiidx]; - request->uuid = uuid; return clientCtx; } } @@ -225,10 +224,6 @@ AFB_clientCtx *ctxClientGet (AFB_request *request, int apiidx) free (clientCtx); return NULL; } - - // if (verbose) fprintf (stderr, "ctxClientGet New uuid=[%s] token=[%s] timestamp=%d\n", clientCtx->uuid, clientCtx->token, clientCtx->timeStamp); - request->context = clientCtx->contexts[apiidx]; - request->uuid = clientCtx->uuid; return clientCtx; }