Commit 80e1dc74 authored by Gildas Bazin's avatar Gildas Bazin

* modules/access/dshow/dshow.cpp: fixed previous fix.
parent 8583966a
......@@ -2,7 +2,7 @@
* dshow.cpp : DirectShow access module for vlc
*****************************************************************************
* Copyright (C) 2002, 2003 VideoLAN
* $Id: dshow.cpp,v 1.23 2003/12/22 16:42:47 gbazin Exp $
* $Id: dshow.cpp,v 1.24 2003/12/22 17:44:58 gbazin Exp $
*
* Author: Gildas Bazin <gbazin@netcourrier.com>
*
......@@ -1446,19 +1446,23 @@ static int FindDevicesCallback( vlc_object_t *p_this, char const *psz_name,
if( !list_devices.size() ) return VLC_SUCCESS;
p_item->ppsz_list_text = NULL;
p_item->ppsz_list =
(char **)realloc( p_item->ppsz_list,
(list_devices.size()+3) * sizeof(char *) );
p_item->ppsz_list_text =
(char **)realloc( p_item->ppsz_list_text,
(list_devices.size()+3) * sizeof(char *) );
list<string>::iterator iter;
for( iter = list_devices.begin(), i = 2; iter != list_devices.end();
iter++, i++ )
{
p_item->ppsz_list[i] = strdup( iter->c_str() );
p_item->ppsz_list_text[i] = NULL;
p_item->i_list++;
}
p_item->ppsz_list[i] = NULL;
p_item->ppsz_list_text[i] = NULL;
return VLC_SUCCESS;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment