|
@@ -646,8 +646,12 @@ acpi_os_create_semaphore(u32 max_units,
|
|
|
}
|
|
|
#ifdef __APPLE__
|
|
|
{
|
|
|
- char *semaphore_name = tmpnam(NULL);
|
|
|
+ static int semaphore_count = 0;
|
|
|
+ char semaphore_name[32];
|
|
|
|
|
|
+ snprintf(semaphore_name, sizeof(semaphore_name), "acpi_sem_%d",
|
|
|
+ semaphore_count++);
|
|
|
+ printf("%s\n", semaphore_name);
|
|
|
sem =
|
|
|
sem_open(semaphore_name, O_EXCL | O_CREAT, 0755,
|
|
|
initial_units);
|