mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-30 08:34:16 +01:00
add mem_stream_make_raw
This commit is contained in:
parent
9cdd5a7b72
commit
976db7b181
3 changed files with 10 additions and 3 deletions
|
@ -66,6 +66,12 @@ static StreamCtxVTable* make_vtable( MemStreamCtxt* stream );
|
||||||
/* Try to keep this the only entry point to this file, and to keep it at the
|
/* Try to keep this the only entry point to this file, and to keep it at the
|
||||||
* top of the file (first executable code).
|
* top of the file (first executable code).
|
||||||
*/
|
*/
|
||||||
|
XWStreamCtxt*
|
||||||
|
mem_stream_make_raw( MPFORMAL VTableMgr* vtmgr )
|
||||||
|
{
|
||||||
|
return mem_stream_make( MPPARM(mpool) vtmgr, NULL, 0, NULL );
|
||||||
|
}
|
||||||
|
|
||||||
XWStreamCtxt*
|
XWStreamCtxt*
|
||||||
mem_stream_make( MPFORMAL VTableMgr* vtmgr, void* closure,
|
mem_stream_make( MPFORMAL VTableMgr* vtmgr, void* closure,
|
||||||
XP_PlayerAddr channelNo, MemStreamCloseCallback onClose )
|
XP_PlayerAddr channelNo, MemStreamCloseCallback onClose )
|
||||||
|
|
|
@ -32,6 +32,8 @@ extern "C" {
|
||||||
typedef void (*MemStreamCloseCallback)( XWStreamCtxt* stream,
|
typedef void (*MemStreamCloseCallback)( XWStreamCtxt* stream,
|
||||||
void* closure );
|
void* closure );
|
||||||
|
|
||||||
|
XWStreamCtxt* mem_stream_make_raw( MPFORMAL VTableMgr* vtmgr);
|
||||||
|
|
||||||
XWStreamCtxt* mem_stream_make( MPFORMAL VTableMgr* vtmgr,
|
XWStreamCtxt* mem_stream_make( MPFORMAL VTableMgr* vtmgr,
|
||||||
void* closure,
|
void* closure,
|
||||||
XP_PlayerAddr addr, /* should be in a
|
XP_PlayerAddr addr, /* should be in a
|
||||||
|
|
|
@ -248,9 +248,8 @@ parseAndDispatch( LaunchParams* params, uint8_t* buf, int len,
|
||||||
CommsAddrRec* addr )
|
CommsAddrRec* addr )
|
||||||
{
|
{
|
||||||
LinSMSData* storage = getStorage( params );
|
LinSMSData* storage = getStorage( params );
|
||||||
XWStreamCtxt* stream = mem_stream_make( MPPARM(params->mpool)
|
XWStreamCtxt* stream = mem_stream_make_raw( MPPARM(params->mpool)
|
||||||
params->vtMgr,
|
params->vtMgr );
|
||||||
NULL, CHANNEL_NONE, NULL );
|
|
||||||
stream_setVersion( stream, CUR_STREAM_VERS );
|
stream_setVersion( stream, CUR_STREAM_VERS );
|
||||||
stream_putBytes( stream, buf, len );
|
stream_putBytes( stream, buf, len );
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue