Rename Tvb_new_real to ByteArray_tvb, as it's a ByteArray function.
Documentation is generated from code. This fixes bug 5199. svn path=/trunk/; revision=37761
This commit is contained in:
parent
6df263d634
commit
5934925554
|
@ -285,7 +285,7 @@ static int ByteArray_tostring(lua_State* L) {
|
|||
WSLUA_RETURN(1); /* A string contaning a representaion of the ByteArray. */
|
||||
}
|
||||
|
||||
static int Tvb_new_real (lua_State *L);
|
||||
static int ByteArray_tvb (lua_State *L);
|
||||
|
||||
static const luaL_reg ByteArray_methods[] = {
|
||||
{"new", ByteArray_new},
|
||||
|
@ -294,7 +294,7 @@ static const luaL_reg ByteArray_methods[] = {
|
|||
{"append", ByteArray_append},
|
||||
{"subset", ByteArray_subset},
|
||||
{"set_size", ByteArray_set_size},
|
||||
{"tvb", Tvb_new_real},
|
||||
{"tvb", ByteArray_tvb},
|
||||
{"get_index", ByteArray_get_index},
|
||||
{"set_index", ByteArray_set_index},
|
||||
{ NULL, NULL }
|
||||
|
@ -364,14 +364,13 @@ Tvb* push_Tvb(lua_State* L, tvbuff_t* ws_tvb) {
|
|||
|
||||
|
||||
/*
|
||||
* Tvb_new_real(bytearray,name)
|
||||
* ByteArray_tvb(name)
|
||||
*/
|
||||
WSLUA_CONSTRUCTOR Tvb_new_real (lua_State *L) {
|
||||
WSLUA_CONSTRUCTOR ByteArray_tvb (lua_State *L) {
|
||||
/* Creates a new Tvb from a bytearray (it gets added to the current frame too) */
|
||||
#define WSLUA_ARG_Tvb_new_real_BYTEARRAY 1 /* The data source for this Tvb. */
|
||||
#define WSLUA_ARG_Tvb_new_real_NAME 2 /* The name to be given to the new data-source. */
|
||||
#define WSLUA_ARG_ByteArray_tvb_NAME 2 /* The name to be given to the new data-source. */
|
||||
ByteArray ba = checkByteArray(L,1);
|
||||
const gchar* name = luaL_optstring(L,WSLUA_ARG_Tvb_new_real_NAME,"Unnamed") ;
|
||||
const gchar* name = luaL_optstring(L,WSLUA_ARG_ByteArray_tvb_NAME,"Unnamed") ;
|
||||
guint8* data;
|
||||
Tvb tvb;
|
||||
|
||||
|
|
Loading…
Reference in New Issue