From: cwolf Date: Thu, 13 Sep 2001 21:38:45 +0000 (+0000) Subject: Drop requirement for shared memory segment for win32 X-Git-Tag: v1.3.3~918 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b9ac7ec33025027ffe620297945f898ab3dc9844;p=platform%2Fupstream%2Flibvorbis.git Drop requirement for shared memory segment for win32 svn path=/trunk/vorbis/; revision=2030 --- diff --git a/lib/vorbisenc.c b/lib/vorbisenc.c index 8d16bdc..7270551 100644 --- a/lib/vorbisenc.c +++ b/lib/vorbisenc.c @@ -11,7 +11,7 @@ ******************************************************************** function: simple programmatic interface for encoder mode setup - last mod: $Id: vorbisenc.c,v 1.15 2001/09/07 08:42:30 cwolf Exp $ + last mod: $Id: vorbisenc.c,v 1.16 2001/09/13 21:38:45 cwolf Exp $ ********************************************************************/ @@ -37,6 +37,8 @@ #if defined(_MSC_VER) && defined(STANDALONE_VORBISENC_DLL) # include "shmmap.h" + SHARED_MAP *g_shared_map; + # define _time_P g_shared_map->p_time_P # define _floor_P g_shared_map->p_floor_P # define _residue_P g_shared_map->p_residue_P @@ -49,6 +51,13 @@ static void codec_setup_partialcopy(codec_setup_info *ci, codec_setup_info *cs){ int i; +#if defined(_MSC_VER) && defined(STANDALONE_VORBISENC_DLL) + int maplen; + + if ((g_shared_map = table_map2mem(&maplen)) == (SHARED_MAP*)0) + ; /* some error handling for memory exhaustion */ +#endif + memcpy(ci,cs,sizeof(codec_setup_info)); /* to get the flat numbers */ /* codebooks */