Commit 528a21a0 authored by Jon Lech Johansen's avatar Jon Lech Johansen

* ./src/misc/configuration.c: win32 UNICODE fixes.

parent 1940820e
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* configuration.c management of the modules configuration * configuration.c management of the modules configuration
***************************************************************************** *****************************************************************************
* Copyright (C) 2001-2004 VideoLAN * Copyright (C) 2001-2004 VideoLAN
* $Id: configuration.c,v 1.72 2004/01/06 12:02:06 zorglub Exp $ * $Id: configuration.c,v 1.73 2004/01/09 19:45:46 jlj Exp $
* *
* Authors: Gildas Bazin <gbazin@netcourrier.com> * Authors: Gildas Bazin <gbazin@netcourrier.com>
* *
...@@ -53,8 +53,11 @@ ...@@ -53,8 +53,11 @@
#if defined( HAVE_SYS_TYPES_H ) #if defined( HAVE_SYS_TYPES_H )
# include <sys/types.h> # include <sys/types.h>
#endif #endif
#if defined( WIN32 ) && !defined( UNDER_CE ) #if defined( WIN32 )
# if !defined( UNDER_CE )
# include <direct.h> # include <direct.h>
# endif
#include <tchar.h>
#endif #endif
...@@ -1505,7 +1508,7 @@ char *config_GetHomeDir( void ) ...@@ -1505,7 +1508,7 @@ char *config_GetHomeDir( void )
#if defined(WIN32) || defined(UNDER_CE) #if defined(WIN32) || defined(UNDER_CE)
typedef HRESULT (WINAPI *SHGETFOLDERPATH)( HWND, int, HANDLE, DWORD, typedef HRESULT (WINAPI *SHGETFOLDERPATH)( HWND, int, HANDLE, DWORD,
LPTSTR ); LPSTR );
# define CSIDL_FLAG_CREATE 0x8000 # define CSIDL_FLAG_CREATE 0x8000
# define CSIDL_APPDATA 0x1A # define CSIDL_APPDATA 0x1A
# define SHGFP_TYPE_CURRENT 0 # define SHGFP_TYPE_CURRENT 0
...@@ -1514,10 +1517,10 @@ char *config_GetHomeDir( void ) ...@@ -1514,10 +1517,10 @@ char *config_GetHomeDir( void )
SHGETFOLDERPATH SHGetFolderPath ; SHGETFOLDERPATH SHGetFolderPath ;
/* load the shfolder dll to retrieve SHGetFolderPath */ /* load the shfolder dll to retrieve SHGetFolderPath */
if( ( shfolder_dll = LoadLibrary("shfolder.dll") ) != NULL ) if( ( shfolder_dll = LoadLibrary( _T("SHFolder.dll") ) ) != NULL )
{ {
SHGetFolderPath = (void *)GetProcAddress( shfolder_dll, SHGetFolderPath = (void *)GetProcAddress( shfolder_dll,
"SHGetFolderPathA" ); _T("SHGetFolderPathA") );
if ( SHGetFolderPath != NULL ) if ( SHGetFolderPath != NULL )
{ {
p_homedir = (char *)malloc( MAX_PATH ); p_homedir = (char *)malloc( MAX_PATH );
......
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