Commit 5caddf2dc59bbed4ec401b36d6266ff93f6ddc25

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

Pequenos ajustes na estrutura de sessao

Showing 1 changed file with 12 additions and 12 deletions   Show diff stats
ctlr.c
... ... @@ -134,18 +134,18 @@ void ctlr_reinit(H3270 *session, unsigned cmask)
134 134 if (cmask & MODEL_CHANGE)
135 135 {
136 136 /* Allocate buffers */
137   - struct ea *tmp;
  137 + struct lib3270_ea *tmp;
138 138 size_t sz = (session->maxROWS * session->maxCOLS);
139 139  
140   - session->buffer[0] = tmp = lib3270_calloc(sizeof(struct ea), sz+1, session->buffer[0]);
  140 + session->buffer[0] = tmp = lib3270_calloc(sizeof(struct lib3270_ea), sz+1, session->buffer[0]);
141 141 session->ea_buf = tmp + 1;
142 142  
143   - session->buffer[1] = tmp = lib3270_calloc(sizeof(struct ea),sz+1,session->buffer[1]);
  143 + session->buffer[1] = tmp = lib3270_calloc(sizeof(struct lib3270_ea),sz+1,session->buffer[1]);
144 144 session->aea_buf = tmp + 1;
145 145  
146 146 session->text = lib3270_calloc(sizeof(struct lib3270_text),sz,session->text);
147 147  
148   - Replace(session->zero_buf, (unsigned char *)Calloc(sizeof(struct ea),sz));
  148 + Replace(session->zero_buf, (unsigned char *)Calloc(sizeof(struct lib3270_ea),sz));
149 149  
150 150 session->cursor_addr = 0;
151 151 session->buffer_addr = 0;
... ... @@ -2270,7 +2270,7 @@ ctlr_clear(H3270 *session, Boolean can_snap)
2270 2270 #endif /*]*/
2271 2271  
2272 2272 /* Clear the screen. */
2273   - (void) memset((char *)session->ea_buf, 0, session->rows*session->cols*sizeof(struct ea));
  2273 + (void) memset((char *)session->ea_buf, 0, session->rows*session->cols*sizeof(struct lib3270_ea));
2274 2274 cursor_move(session,0);
2275 2275 session->buffer_addr = 0;
2276 2276 lib3270_unselect(session);
... ... @@ -2469,9 +2469,9 @@ ctlr_bcopy(int baddr_from, int baddr_to, int count, int move_ea)
2469 2469 /* Move the characters. */
2470 2470 if (memcmp((char *) &h3270.ea_buf[baddr_from],
2471 2471 (char *) &h3270.ea_buf[baddr_to],
2472   - count * sizeof(struct ea))) {
  2472 + count * sizeof(struct lib3270_ea))) {
2473 2473 (void) memmove(&h3270.ea_buf[baddr_to], &h3270.ea_buf[baddr_from],
2474   - count * sizeof(struct ea));
  2474 + count * sizeof(struct lib3270_ea));
2475 2475 REGION_CHANGED(&h3270,baddr_to, baddr_to + count);
2476 2476 }
2477 2477 /* XXX: What about move_ea? */
... ... @@ -2485,9 +2485,9 @@ ctlr_bcopy(int baddr_from, int baddr_to, int count, int move_ea)
2485 2485 void ctlr_aclear(H3270 *session, int baddr, int count, int clear_ea)
2486 2486 {
2487 2487 if (memcmp((char *) &session->ea_buf[baddr], (char *) session->zero_buf,
2488   - count * sizeof(struct ea))) {
  2488 + count * sizeof(struct lib3270_ea))) {
2489 2489 (void) memset((char *) &session->ea_buf[baddr], 0,
2490   - count * sizeof(struct ea));
  2490 + count * sizeof(struct lib3270_ea));
2491 2491 REGION_CHANGED(session,baddr, baddr + count);
2492 2492 }
2493 2493 /* XXX: What about clear_ea? */
... ... @@ -2509,10 +2509,10 @@ void ctlr_scroll(H3270 *hSession)
2509 2509 /* Synchronize pending changes prior to this. */
2510 2510  
2511 2511 /* Move ea_buf. */
2512   - (void) memmove(&hSession->ea_buf[0], &hSession->ea_buf[h3270.cols],qty * sizeof(struct ea));
  2512 + (void) memmove(&hSession->ea_buf[0], &hSession->ea_buf[h3270.cols],qty * sizeof(struct lib3270_ea));
2513 2513  
2514 2514 /* Clear the last line. */
2515   - (void) memset((char *) &hSession->ea_buf[qty], 0, hSession->cols * sizeof(struct ea));
  2515 + (void) memset((char *) &hSession->ea_buf[qty], 0, hSession->cols * sizeof(struct lib3270_ea));
2516 2516  
2517 2517 hSession->display(hSession);
2518 2518  
... ... @@ -2549,7 +2549,7 @@ void ctlr_altbuffer(H3270 *session, int alt)
2549 2549  
2550 2550 if (alt != session->is_altbuffer)
2551 2551 {
2552   - struct ea *etmp;
  2552 + struct lib3270_ea *etmp;
2553 2553  
2554 2554 etmp = session->ea_buf;
2555 2555 session->ea_buf = session->aea_buf;
... ...