search for: ei_x_encode_atom

Displaying 1 result from an estimated 1 matches for "ei_x_encode_atom".

2020 Jun 01
1
[PATCH] erlang: Port to libei for Erlang 23
...) { - ETERM *error = erl_mk_atom ("error"); - ETERM *msg = erl_mk_string (guestfs_last_error (g)); - ETERM *num = erl_mk_int (guestfs_last_errno (g)); - ETERM *t[3] = { error, msg, num }; - return erl_mk_tuple (t, 3); + if (ei_x_encode_tuple_header (buff, 3) != 0) return -1; + if (ei_x_encode_atom (buff, "error") != 0) return -1; + if (ei_x_encode_string (buff, guestfs_last_error (g)) != 0) return -1; + if (ei_x_encode_long (buff, guestfs_last_errno (g)) != 0) return -1; + return 0; } -ETERM * -unknown_function (ETERM *fun) +int +unknown_function (ei_x_buff *buff, const char...