[misc] use the more univerasal _mm_alloc() instead of _aligned_malloc()

* Also ensure that our buffers are aligned
* Also remove the use of static buffers in ms-sys
This commit is contained in:
Pete Batard 2016-06-10 12:42:43 +01:00
parent 3fdf622933
commit e76f60a3e8
11 changed files with 125 additions and 113 deletions

View file

@ -331,7 +331,7 @@ BOOL Identify(HANDLE hPhysical)
// You'll get an error here if your compiler does not properly pack the IDENTIFY struct
COMPILE_TIME_ASSERT(sizeof(IDENTIFY_DEVICE_DATA) == 512);
idd = (IDENTIFY_DEVICE_DATA*)_aligned_malloc(sizeof(IDENTIFY_DEVICE_DATA), 0x10);
idd = (IDENTIFY_DEVICE_DATA*)_mm_malloc(sizeof(IDENTIFY_DEVICE_DATA), 0x10);
if (idd == NULL)
return FALSE;
@ -352,7 +352,7 @@ BOOL Identify(HANDLE hPhysical)
if (i >= ARRAYSIZE(pt))
uprintf("NO ATA FOR YOU!\n");
_aligned_free(idd);
_mm_free(idd);
return TRUE;
}
#endif