[vlc-devel] commit: Qt: Simple prefs/input: fix variable handling (Francois Cartegnie )
git version control
git at videolan.org
Sun Oct 4 18:17:39 CEST 2009
vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Thu Oct 1 18:12:14 2009 +0200| [2cee8e42859d99895603f5617ce7dee6c3beaa93] | committer: Jean-Baptiste Kempf
Qt: Simple prefs/input: fix variable handling
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=2cee8e42859d99895603f5617ce7dee6c3beaa93
---
modules/gui/qt4/components/simple_preferences.cpp | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/modules/gui/qt4/components/simple_preferences.cpp b/modules/gui/qt4/components/simple_preferences.cpp
index c1ecda9..6f98fe2 100644
--- a/modules/gui/qt4/components/simple_preferences.cpp
+++ b/modules/gui/qt4/components/simple_preferences.cpp
@@ -719,13 +719,14 @@ void SPrefsPanel::apply()
case SPrefsInputAndCodecs:
{
/* Device default selection */
- const char *psz_devicepath =
- qtu( qobject_cast<QLineEdit *>(optionWidgets[inputLE] )->text() );
+ char *psz_devicepath =
+ strdup( qtu( qobject_cast<QLineEdit *>(optionWidgets[inputLE] )->text() ) );
if( !EMPTY_STR( psz_devicepath ) )
{
config_PutPsz( p_intf, "dvd", psz_devicepath );
config_PutPsz( p_intf, "vcd", psz_devicepath );
config_PutPsz( p_intf, "cd-audio", psz_devicepath );
+ free( psz_devicepath );
}
#define CaCi( name, int ) config_PutInt( p_intf, name, int * i_comboValue )
More information about the vlc-devel
mailing list