[feat] support new screen capture method by using ScreenCaptureKit on MacOSX

This commit is contained in:
dijunkun
2024-10-18 17:20:52 +08:00
parent 9ed3ab9929
commit b5bb62bd22
11 changed files with 542 additions and 11 deletions

View File

@@ -55,7 +55,8 @@ std::string GetMac() {
const unsigned char *base =
(const unsigned char *)&dlAddr->sdl_data[dlAddr->sdl_nlen];
for (int i = 0; i < dlAddr->sdl_alen; i++) {
len += sprintf(mac_addr + len, "%.2X", base[i]);
len +=
snprintf(mac_addr + len, sizeof(mac_addr) - len, "%.2X", base[i]);
}
}
cursor = cursor->ifa_next;