Commit 0c837bc7001adab47635b19d24adeb7be8aa40a7
1 parent
67279f8a
Exists in
master
and in
5 other branches
Trabalhando na implementacao HLLAPI - Ainda esta apresentando segfaults ao devolver uma string ao VB
Showing
2 changed files
with
3 additions
and
3 deletions
Show diff stats
src/include/pw3270/hllapi.h
| ... | ... | @@ -63,7 +63,7 @@ extern "C" { |
| 63 | 63 | |
| 64 | 64 | #ifdef _WIN32 |
| 65 | 65 | // http://www.mingw.org/wiki/Visual_Basic_DLL |
| 66 | - __declspec (dllexport) int __stdcall hllapi(const unsigned long *func, char *str, unsigned short *length, unsigned short *rc); | |
| 66 | + __declspec (dllexport) int __stdcall hllapi(LPWORD func, LPSTR str, LPWORD length, LPWORD rc); | |
| 67 | 67 | #else |
| 68 | 68 | LIB3270_EXPORT int hllapi(const unsigned long *func, char *str, unsigned short *length, unsigned short *rc); |
| 69 | 69 | #endif // _WIN32 | ... | ... |
src/plugins/remotectl/hllapi.c
| ... | ... | @@ -143,7 +143,7 @@ |
| 143 | 143 | } |
| 144 | 144 | |
| 145 | 145 | #ifdef _WIN32 |
| 146 | - __declspec (dllexport) int __stdcall hllapi(const unsigned long *func, char *str, unsigned short *length, unsigned short *rc) | |
| 146 | + __declspec (dllexport) int __stdcall hllapi(LPWORD func, LPSTR str, LPWORD length, LPWORD rc) | |
| 147 | 147 | #else |
| 148 | 148 | LIB3270_EXPORT int hllapi(const unsigned long *func, char *str, unsigned short *length, unsigned short *rc) |
| 149 | 149 | #endif // _WIN32 |
| ... | ... | @@ -221,7 +221,7 @@ |
| 221 | 221 | *ptr = '.'; |
| 222 | 222 | } |
| 223 | 223 | |
| 224 | - fprintf(arq,"func: %ld\nresult: %d\nrc: %d\nLength: %d\nstring: [%s]\n",*func,result,*rc, *length, str); | |
| 224 | + fprintf(arq,"func: %d\nresult: %d\nrc: %d\nLength: %d\nstring: [%s]\n",*func,result,*rc, *length, str); | |
| 225 | 225 | fclose(arq); |
| 226 | 226 | } |
| 227 | 227 | #endif // DEBUG | ... | ... |