Hi, That function no longer exists. Functions and callbacks now return the proper status code. Usually something < 0 is an error, which maps to an UV_EXXX constant.
Cheers, On Wed, Jan 15, 2014 at 6:02 PM, Eduardo Nunes Pereira < [email protected]> wrote: > Hi, > > I was reading the examples of the book about libuv ( > http://nikhilm.github.io/uvbook/), and run some samples, but i stopped at > a error with uv_last_error, then after checking my the master branch (that > was cloned), realized which that function was removed from master branch. > My question is how to handle now, for example from given sample: > > void read_stdin(uv_stream_t *stream, ssize_t nread, uv_buf_t buf) { > if (nread == -1) { > if (uv_last_error(loop).code == UV_EOF) { > uv_close((uv_handle_t*)&stdin_pipe, NULL); > uv_close((uv_handle_t*)&stdout_pipe, NULL); > uv_close((uv_handle_t*)&file_pipe, NULL); > } > } > else { > if (nread > 0) { > write_data((uv_stream_t*)&stdout_pipe, nread, buf, > on_stdout_write); > write_data((uv_stream_t*)&file_pipe, nread, buf, > on_file_write); > } > } > if (buf.base) > free(buf.base); > } > > Thanks > > -- > You received this message because you are subscribed to the Google Groups > "libuv" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > Visit this group at http://groups.google.com/group/libuv. > For more options, visit https://groups.google.com/groups/opt_out. > -- /Saúl http://saghul.net | http://about.me/saghul -- You received this message because you are subscribed to the Google Groups "libuv" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/libuv. For more options, visit https://groups.google.com/groups/opt_out.
