[warnings] fix types and guards
Fix some broken define guards and a wrong return type
This commit is contained in:
parent
1e24fcd9a4
commit
622fcc7025
@ -1188,7 +1188,7 @@ static BOOL rdg_auth_init(rdpRdg* rdg, rdpTls* tls, TCHAR* authPkg)
|
|||||||
if (!credssp_auth_init(rdg->auth, authPkg, tls->Bindings))
|
if (!credssp_auth_init(rdg->auth, authPkg, tls->Bindings))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
bool doSCLogon = freerdp_settings_get_bool(settings, FreeRDP_SmartcardLogon);
|
BOOL doSCLogon = freerdp_settings_get_bool(settings, FreeRDP_SmartcardLogon);
|
||||||
if (doSCLogon)
|
if (doSCLogon)
|
||||||
{
|
{
|
||||||
if (!smartcard_getCert(context, &rdg->smartcard, TRUE))
|
if (!smartcard_getCert(context, &rdg->smartcard, TRUE))
|
||||||
|
@ -611,9 +611,10 @@ static const char* flagsToStr(char* buffer, size_t size, DWORD flags)
|
|||||||
|
|
||||||
BOOL SetFileAttributesA(LPCSTR lpFileName, DWORD dwFileAttributes)
|
BOOL SetFileAttributesA(LPCSTR lpFileName, DWORD dwFileAttributes)
|
||||||
{
|
{
|
||||||
struct stat st;
|
|
||||||
int fd = 0;
|
|
||||||
BOOL rc = FALSE;
|
BOOL rc = FALSE;
|
||||||
|
#ifdef WINPR_HAVE_FCNTL_H
|
||||||
|
struct stat st = { 0 };
|
||||||
|
int fd = 0;
|
||||||
|
|
||||||
if (dwFileAttributes & ~FILE_ATTRIBUTE_READONLY)
|
if (dwFileAttributes & ~FILE_ATTRIBUTE_READONLY)
|
||||||
{
|
{
|
||||||
@ -645,6 +646,7 @@ BOOL SetFileAttributesA(LPCSTR lpFileName, DWORD dwFileAttributes)
|
|||||||
rc = TRUE;
|
rc = TRUE;
|
||||||
fail:
|
fail:
|
||||||
close(fd);
|
close(fd);
|
||||||
|
#endif
|
||||||
return rc;
|
return rc;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user