X-Git-Url: http://dolda2000.com/gitweb/?a=blobdiff_plain;f=include%2Fdoldaconnect%2Fuilib.h;h=397c49e5ffdd25ad8a7116cad88a8aef6f7e1791;hb=c8c6be241f782e0d3fecb0fbfb042fd28a3f5dad;hp=ac717fbc64b9334f6824d8a2f8b6dfe9c55ace76;hpb=34a61ecbf51b9115f2ba4cc987952413e4c5c1ea;p=doldaconnect.git diff --git a/include/doldaconnect/uilib.h b/include/doldaconnect/uilib.h index ac717fb..397c49e 100644 --- a/include/doldaconnect/uilib.h +++ b/include/doldaconnect/uilib.h @@ -3,6 +3,10 @@ #include +#define DC_LATEST 3 + +typedef long long dc_lnum_t; + struct dc_response { struct dc_response *next, *prev; @@ -30,12 +34,15 @@ struct dc_intresp union { int num; + dc_lnum_t lnum; wchar_t *str; double flnum; } val; } *argv; }; +char *dc_srv_local; + int dc_init(void); void dc_cleanup(void); void dc_disconnect(void); @@ -48,9 +55,13 @@ int dc_getstate(void); int dc_queuecmd(int (*callback)(struct dc_response *), void *data, ...); int dc_handleread(void); int dc_handlewrite(void); -int dc_connect(char *host, int port); +int dc_connect(char *host); +int dc_connectsync(char *host, struct dc_response **respbuf); +int dc_connectsync2(char *host, int rev); struct dc_intresp *dc_interpret(struct dc_response *resp); void dc_freeires(struct dc_intresp *ires); +int dc_checkprotocol(struct dc_response *resp, int revision); const char *dc_gethostname(void); +int dc_getfd(void); #endif