Skip to content

Commit

Permalink
Make restGetFile extern C
Browse files Browse the repository at this point in the history
  • Loading branch information
Buggynours committed Dec 3, 2019
1 parent 64b1b95 commit 579d572
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
2 changes: 2 additions & 0 deletions storage/connect/restget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ using namespace concurrency::streams; // Asynchronous streams

typedef const char* PCSZ;

extern "C" int restGetFile(char* m, bool xt, PCSZ http, PCSZ uri, PCSZ fn);

/***********************************************************************/
/* Make a local copy of the requested file. */
/***********************************************************************/
Expand Down
6 changes: 3 additions & 3 deletions storage/connect/tabrest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@
#define _MAX_PATH 260
#if !defined(__WIN__)
#define __stdcall
//#if !defined(REST_SOURCE)
//#include <dlfcn.h> // dlopen(), dlclose(), dlsym() ...
//#endif
#if !defined(REST_SOURCE)
#include <dlfcn.h> // dlopen(), dlclose(), dlsym() ...
#endif
#endif // !__WIN__
#define _OS_H_INCLUDED // Prevent os.h to be called
#endif // !MARIADB
Expand Down
4 changes: 3 additions & 1 deletion storage/connect/tabrest.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@ typedef int(__stdcall* XGETREST) (char*, bool, PCSZ, PCSZ, PCSZ);
/* Functions used by REST. */
/***********************************************************************/
XGETREST GetRestFunction(PGLOBAL g);
int restGetFile(char* m, bool x, PCSZ http, PCSZ uri, PCSZ fn);
#if defined(REST_SOURCE)
extern "C" int restGetFile(char* m, bool xt, PCSZ http, PCSZ uri, PCSZ fn);
#endif // REST_SOURCE
#if defined(MARIADB)
PQRYRES RESTColumns(PGLOBAL g, PTOS tp, char* tab, char* db, bool info);
#endif // !MARIADB
Expand Down

0 comments on commit 579d572

Please sign in to comment.