Changeset 29648 in vbox for trunk/src/VBox
- Timestamp:
- May 18, 2010 4:15:42 PM (15 years ago)
- Location:
- trunk/src/VBox/Runtime/r0drv/linux
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/r0drv/linux/semevent-r0drv-linux.c
r28800 r29648 143 143 long lTimeout = cMillies == RT_INDEFINITE_WAIT ? MAX_SCHEDULE_TIMEOUT : msecs_to_jiffies(cMillies); 144 144 #ifdef IPRT_DEBUG_SEMS 145 snprintf(current->comm, TASK_COMM_LEN, "e%lx", IPRT_DEBUG_SEMS_ADDRESS(pThis));145 snprintf(current->comm, sizeof(current->comm), "e%lx", IPRT_DEBUG_SEMS_ADDRESS(pThis)); 146 146 #endif 147 147 for (;;) … … 183 183 finish_wait(&pThis->Head, &Wait); 184 184 #ifdef IPRT_DEBUG_SEMS 185 snprintf(current->comm, TASK_COMM_LEN, "e%lx:%d", IPRT_DEBUG_SEMS_ADDRESS(pThis), rc);185 snprintf(current->comm, sizeof(current->comm), "e%lx:%d", IPRT_DEBUG_SEMS_ADDRESS(pThis), rc); 186 186 #endif 187 187 return rc; -
trunk/src/VBox/Runtime/r0drv/linux/semeventmulti-r0drv-linux.c
r28800 r29648 167 167 long lTimeout = cMillies == RT_INDEFINITE_WAIT ? MAX_SCHEDULE_TIMEOUT : msecs_to_jiffies(cMillies); 168 168 #ifdef IPRT_DEBUG_SEMS 169 snprintf(current->comm, TASK_COMM_LEN, "E%lx", IPRT_DEBUG_SEMS_ADDRESS(pThis));169 snprintf(current->comm, sizeof(current->comm), "E%lx", IPRT_DEBUG_SEMS_ADDRESS(pThis)); 170 170 #endif 171 171 for (;;) … … 207 207 finish_wait(&pThis->Head, &Wait); 208 208 #ifdef IPRT_DEBUG_SEMS 209 snprintf(current->comm, TASK_COMM_LEN, "E%lx:%d", IPRT_DEBUG_SEMS_ADDRESS(pThis), rc);209 snprintf(current->comm, sizeof(current->comm), "E%lx:%d", IPRT_DEBUG_SEMS_ADDRESS(pThis), rc); 210 210 #endif 211 211 return rc; -
trunk/src/VBox/Runtime/r0drv/linux/semfastmutex-r0drv-linux.c
r28800 r29648 115 115 116 116 #ifdef IPRT_DEBUG_SEMS 117 snprintf(current->comm, TASK_COMM_LEN, "d%lx", IPRT_DEBUG_SEMS_ADDRESS(pThis));117 snprintf(current->comm, sizeof(current->comm), "d%lx", IPRT_DEBUG_SEMS_ADDRESS(pThis)); 118 118 #endif 119 119 down(&pThis->Semaphore); 120 120 #ifdef IPRT_DEBUG_SEMS 121 snprintf(current->comm, TASK_COMM_LEN, "o%lx", IPRT_DEBUG_SEMS_ADDRESS(pThis));121 snprintf(current->comm, sizeof(current->comm), "o%lx", IPRT_DEBUG_SEMS_ADDRESS(pThis)); 122 122 AssertRelease(pThis->Owner == NIL_RTNATIVETHREAD); 123 123 ASMAtomicUoWriteSize(&pThis->Owner, RTThreadNativeSelf()); … … 143 143 up(&pThis->Semaphore); 144 144 #ifdef IPRT_DEBUG_SEMS 145 snprintf(current->comm, TASK_COMM_LEN, "u%lx", IPRT_DEBUG_SEMS_ADDRESS(pThis));145 snprintf(current->comm, sizeof(current->comm), "u%lx", IPRT_DEBUG_SEMS_ADDRESS(pThis)); 146 146 #endif 147 147 return VINF_SUCCESS; -
trunk/src/VBox/Runtime/r0drv/linux/the-linux-kernel.h
r28800 r29648 322 322 #ifdef IPRT_DEBUG_SEMS 323 323 # define IPRT_DEBUG_SEMS_STATE(pThis, chState) \ 324 snprintf(current->comm, TASK_COMM_LEN, "%c%lx", (chState), IPRT_DEBUG_SEMS_ADDRESS(pThis));324 snprintf(current->comm, sizeof(current->comm), "%c%lx", (chState), IPRT_DEBUG_SEMS_ADDRESS(pThis)); 325 325 #else 326 326 # define IPRT_DEBUG_SEMS_STATE(pThis, chState) do { } while (0) … … 333 333 #ifdef IPRT_DEBUG_SEMS 334 334 # define IPRT_DEBUG_SEMS_STATE_RC(pThis, chState, rc) \ 335 snprintf(current->comm, TASK_COMM_LEN, "%c%lx:%d", (chState), IPRT_DEBUG_SEMS_ADDRESS(pThis), rc);335 snprintf(current->comm, sizeof(current->comm), "%c%lx:%d", (chState), IPRT_DEBUG_SEMS_ADDRESS(pThis), rc); 336 336 #else 337 337 # define IPRT_DEBUG_SEMS_STATE_RC(pThis, chState, rc) do { } while (0)
Note:
See TracChangeset
for help on using the changeset viewer.