From d38c1e88fa656e2a7e4b235565b1b046fb2942ec Mon Sep 17 00:00:00 2001 From: vida Date: Mon, 10 Apr 2006 12:48:54 +0000 Subject: [PATCH] Re-definition of some global variable and function parameter. git-svn-id: svn+ssh://cvs.lpds.sztaki.hu/var/lib/svn/szdg/dcapi/trunk@444 a7169a2c-3604-0410-bc95-c702d8d87f7a --- dcapi/local/dc.c | 4 +++- dcapi/local/dc_local.h | 12 ++++++++++-- dcapi/local/events.c | 2 +- 3 files changed, 14 insertions(+), 4 deletions(-) diff --git a/dcapi/local/dc.c b/dcapi/local/dc.c index 8b6704c8b9..af7fea1e1e 100644 --- a/dcapi/local/dc.c +++ b/dcapi/local/dc.c @@ -18,7 +18,9 @@ DC_ResultCallback _dc_resultcb; DC_SubresultCallback _dc_subresultcb; DC_MessageCallback _dc_messagecb; -static uuid_t project_uuid; +char project_uuid_str[37]; +uuid_t project_uuid; +int sleep_interval; /******************************************************************** * API functions diff --git a/dcapi/local/dc_local.h b/dcapi/local/dc_local.h index bf8cd56ad7..7c602ade64 100644 --- a/dcapi/local/dc_local.h +++ b/dcapi/local/dc_local.h @@ -91,13 +91,21 @@ extern DC_SubresultCallback _dc_subresultcb; extern DC_MessageCallback _dc_messagecb; extern char project_uuid_str[37]; +extern uuid_t project_uuid; extern int sleep_interval; /******************************************************************** * Function prototypes */ -int rm_init(const char *config_workdir, const char *config_uuid); +/* Allocates a physical file descriptor */ +DC_PhysicalFile *_DC_createPhysicalFile(const char *label, + const char *path); + +/* De-allocates a physical file descriptor */ +void _DC_destroyPhysicalFile(DC_PhysicalFile *file); + +int _DC_searchForEvents(); /* Parses the project's config.xml */ int _DC_parseConfigXML(const char *file); @@ -134,7 +142,7 @@ DC_PhysicalFile *_DC_createPhysicalFile(const char *label, void _DC_destroyPhysicalFile(DC_PhysicalFile *file); /* Creates a new DC_Result */ -DC_Result *_DC_createResult(const char *wu_name, const char *xml_doc_in); +DC_Result *_DC_createResult(const char *wu_name); /* Destroys a DC_Result */ void _DC_destroyResult(DC_Result *result); diff --git a/dcapi/local/events.c b/dcapi/local/events.c index 07f2af8fed..2e16284614 100644 --- a/dcapi/local/events.c +++ b/dcapi/local/events.c @@ -9,13 +9,13 @@ int DC_processEvents(int timeout) { - if (!_dc_resultcb || !_dc_subresultcb || !_dc_messagecb) { DC_log(LOG_ERR, "DC_processEvents: callbacks are not set up"); return DC_ERR_CONFIG; } + _DC_searchForEvents(); return 0; }