Commit 243e4662e154f7034c8b143c32433352630a8379

Authored by perry.werneck@gmail.com
1 parent 83679624

Ajustes em função do novo método de conexão

Showing 3 changed files with 4 additions and 5 deletions   Show diff stats
api.h
... ... @@ -319,7 +319,6 @@
319 319  
320 320 /* Get connection info */
321 321 #define get_connected_lu(h) lib3270_get_luname(h)
322   -// #define get_current_host(h) lib3270_get_host(h)
323 322  
324 323 LOCAL_EXTERN SCRIPT_STATE status_script(SCRIPT_STATE state);
325 324  
... ...
host.c
... ... @@ -714,7 +714,7 @@ LIB3270_EXPORT const char * lib3270_set_host(H3270 *h, const char *n)
714 714 Replace(h->host.full,
715 715 lib3270_strdup_printf(
716 716 "%s%s:%s%s%s",
717   - h->host.opt&LIB3270_CONNECT_OPTION_SSL ? "L:" : "",
  717 + h->host.opt&LIB3270_CONNECT_OPTION_SSL ? "tn3270s://" : "",
718 718 hostname,
719 719 srvc,
720 720 *query ? "?" : "",
... ... @@ -727,10 +727,10 @@ LIB3270_EXPORT const char * lib3270_set_host(H3270 *h, const char *n)
727 727 return h->host.current;
728 728 }
729 729  
730   -LIB3270_EXPORT const char * lib3270_get_host(H3270 *h)
  730 +LIB3270_EXPORT const char * lib3270_get_hostname(H3270 *h)
731 731 {
732 732 CHECK_SESSION_HANDLE(h);
733   - return h->host.full;
  733 + return h->host.current;
734 734 }
735 735  
736 736 LIB3270_EXPORT int lib3270_reconnect(H3270 *hSession,int wait)
... ...
macros.c
... ... @@ -183,7 +183,7 @@
183 183 {
184 184 const char * luname = (const char *) lib3270_get_luname(hSession);
185 185 const char * state = get_state(hSession);
186   - const char * host = (const char *) lib3270_get_host(hSession);
  186 + const char * host = (const char *) lib3270_get_hostname(hSession);
187 187 char * rsp;
188 188 size_t sz;
189 189  
... ...