On Sun, 17 Jul 2011 04:11:25 -0700 "Enlightenment SVN" <[email protected]> wrote:
> Log: > ecore_con : fix compilation on Windows > > Author: caro > Date: 2011-07-17 04:11:25 -0700 (Sun, 17 Jul 2011) > New Revision: 61439 > Trac: http://trac.enlightenment.org/e/changeset/61439 > > Modified: > trunk/ecore/src/lib/ecore_con/ecore_con_local_win32.c > > Modified: trunk/ecore/src/lib/ecore_con/ecore_con_local_win32.c > =================================================================== > --- trunk/ecore/src/lib/ecore_con/ecore_con_local_win32.c 2011-07-17 > 10:48:05 UTC (rev 61438) +++ > trunk/ecore/src/lib/ecore_con/ecore_con_local_win32.c 2011-07-17 > 11:11:25 UTC (rev 61439) @@ -684,10 +684,10 @@ ((svr->type & > ECORE_CON_TYPE) != ECORE_CON_LOCAL_SYSTEM)) return EINA_FALSE; > > - num = svr->write_buf_size - svr->write_buf_offset; > + num = eina_binbuf_length_get(svr->buf) - svr->write_buf_offset; > if (num <= 0) return EINA_TRUE; > > - res = WriteFile(svr->pipe, svr->write_buf + svr->write_buf_offset, num, > &written, NULL); > + res = WriteFile(svr->pipe, eina_binbuf_string_get(svr->buf) + > svr->write_buf_offset, num, &written, NULL); if (!res) > { > char *msg; > @@ -704,12 +704,11 @@ > } > > svr->write_buf_offset += written; > - if (svr->write_buf_offset >= svr->write_buf_size) > + if (svr->write_buf_offset >= eina_binbuf_length_get(svr->buf)) > { > - svr->write_buf_size = 0; > svr->write_buf_offset = 0; > - free(svr->write_buf); > - svr->write_buf = NULL; > + eina_binbuf_free(svr->buf); > + svr->buf = NULL; > svr->want_write = 0; > } > else if (written < (DWORD)num) > @@ -736,10 +735,10 @@ > (type != ECORE_CON_LOCAL_SYSTEM)) > return EINA_FALSE; > > - num = cl->buf_size - cl->buf_offset; > + num = eina_binbuf_length_get(cl->buf) - cl->buf_offset; > if (num <= 0) return EINA_TRUE; > > - res = WriteFile(cl->host_server->pipe, cl->buf + cl->buf_offset, num, > &written, NULL); > + res = WriteFile(cl->host_server->pipe, eina_binbuf_string_get(cl->buf) + > cl->buf_offset, num, &written, NULL); if (!res) > { > char *msg; > @@ -756,11 +755,10 @@ > } > > cl->buf_offset += written; > - if (cl->buf_offset >= cl->buf_size) > + if (cl->buf_offset >= eina_binbuf_length_get(cl->buf)) > { > - cl->buf_size = 0; > cl->buf_offset = 0; > - free(cl->buf); > + eina_binbuf_free(cl->buf); > cl->buf = NULL; > cl->host_server->want_write = 0; > } > > > ------------------------------------------------------------------------------ > AppSumo Presents a FREE Video for the SourceForge Community by Eric > Ries, the creator of the Lean Startup Methodology on "Lean Startup > Secrets Revealed." This video shows you how to validate your ideas, > optimize your ideas and identify your business strategy. > http://p.sf.net/sfu/appsumosfdev2dev > _______________________________________________ > enlightenment-svn mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/enlightenment-svn whoops sorry -- Mike Blumenkrantz Zentific: Coding in binary since '10. ------------------------------------------------------------------------------ AppSumo Presents a FREE Video for the SourceForge Community by Eric Ries, the creator of the Lean Startup Methodology on "Lean Startup Secrets Revealed." This video shows you how to validate your ideas, optimize your ideas and identify your business strategy. http://p.sf.net/sfu/appsumosfdev2dev _______________________________________________ enlightenment-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
