Mercurial > mplayer.hg
changeset 9914:3c856c0fc45e
mem mapped area need to be unmapped.
author | albeu |
---|---|
date | Sat, 12 Apr 2003 13:52:21 +0000 |
parents | 88fe89b46786 |
children | eabe876ab5e2 |
files | osdep/shmem.c osdep/shmem.h |
diffstat | 2 files changed, 9 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/osdep/shmem.c Sat Apr 12 13:45:43 2003 +0000 +++ b/osdep/shmem.c Sat Apr 12 13:52:21 2003 +0000 @@ -94,8 +94,15 @@ } } -void shmem_free(void* p){ +void shmem_free(void* p,int size){ switch(shmem_type){ + case 0: + case 1: + if(munmap(p,size)) { + mp_msg(MSGT_OSDEP, MSGL_ERR, "munmap failed on %p %d bytes: %s\n", + p,size,strerror(errno)); + } + break; case 2: #ifdef HAVE_SHM if (shmdt(p) == -1)