rbutil: Fix some compile warnings under Windows

Change-Id: I8abfbd61066c17297962de1432144692604cf245
This commit is contained in:
Solomon Peachy 2026-07-04 11:13:34 -04:00
parent a3be8d1a12
commit 9a31255ff8
3 changed files with 5 additions and 3 deletions

View file

@ -28,8 +28,10 @@
// Windows Includes
#if defined(Q_OS_WIN32)
#if defined(UNICODE)
#ifndef _UNICODE
#define _UNICODE
#endif
#endif
#include <windows.h>
#include <tchar.h>
#include <lm.h>
@ -489,5 +491,3 @@ QUrl System::systemProxy(void)
return QUrl("");
#endif
}

View file

@ -587,7 +587,7 @@ QStringList Utils::mountpoints(enum MountpointsFilter type)
for(int i=0; i<list.size();i++)
{
wchar_t t[32];
memset(t, 0, 32);
memset(t, 0, sizeof(t));
if(GetVolumeInformationW((LPCWSTR)list.at(i).absolutePath().utf16(),
NULL, 0, NULL, NULL, NULL, t, 32) == 0) {
// on error empty retrieved type -- don't rely on

View file

@ -39,8 +39,10 @@
#include "comboboxviewdelegate.h"
#if defined(Q_OS_WIN32)
#if defined(UNICODE)
#ifndef _UNICODE
#define _UNICODE
#endif
#endif
#include <tchar.h>
#include <windows.h>
#endif