History

Use char instead of str_t

Martin Storsjö committed 12 years ago

Commit f2bd22a1 parent 7b96c6734 files · +131 −135Browse files

Showing the changes to codec/encoder/core/src/slice_multi_threading.cpp (1 of 34 files). Show all

Unified · Split

codec/encoder/core/src/slice_multi_threading.cpp+3−3
@@ -438,7 +438,7 @@ int32_t RequestMtResource (sWelsEncCtx** ppCtx, SWelsSvcCodingParam* pCodingPara · 437 unmodified lines
438 iIdx = 0;438 iIdx = 0;
439 while (iIdx < iThreadNum) {439 while (iIdx < iThreadNum) {
440#if defined(__GNUC__) && !defined(_WIN32) // for posix threading440#if defined(__GNUC__) && !defined(_WIN32) // for posix threading
441 str_t name[SEM_NAME_MAX] = {0};441 char name[SEM_NAME_MAX] = {0};
442 WELS_THREAD_ERROR_CODE err = 0;442 WELS_THREAD_ERROR_CODE err = 0;
443#endif//__GNUC__443#endif//__GNUC__
444 pSmt->pThreadPEncCtx[iIdx].pWelsPEncCtx = (void*) (*ppCtx);444 pSmt->pThreadPEncCtx[iIdx].pWelsPEncCtx = (void*) (*ppCtx);
@@ -568,7 +568,7 @@ void ReleaseMtResource (sWelsEncCtx** ppCtx) { · 123 unmodified lines
568 WelsEventDestroy (&pSmt->pFinUpdateMbListEvent[iIdx]);568 WelsEventDestroy (&pSmt->pFinUpdateMbListEvent[iIdx]);
569#endif//DYNAMIC_SLICE_ASSIGN && TRY_SLICING_BALANCE569#endif//DYNAMIC_SLICE_ASSIGN && TRY_SLICING_BALANCE
570#else570#else
571 str_t ename[SEM_NAME_MAX] = {0};571 char ename[SEM_NAME_MAX] = {0};
572 // length of semaphore name should be system constrained at least on mac 10.7572 // length of semaphore name should be system constrained at least on mac 10.7
573 WelsSnprintf (ename, SEM_NAME_MAX, "sc%d%p", iIdx, (void*) (*ppCtx));573 WelsSnprintf (ename, SEM_NAME_MAX, "sc%d%p", iIdx, (void*) (*ppCtx));
574 WelsEventClose (pSmt->pSliceCodedEvent[iIdx], ename);574 WelsEventClose (pSmt->pSliceCodedEvent[iIdx], ename);
@@ -1219,7 +1219,7 @@ int32_t CreateSliceThreads (sWelsEncCtx* pCtx) { · 644 unmodified lines
1219 if (dwAffinityMask & dwProcessAffinity) { // check if cpu is available1219 if (dwAffinityMask & dwProcessAffinity) { // check if cpu is available
1220 dw = SetThreadAffinityMask (pCtx->pSliceThreading->pThreadHandles[iIdx], dwAffinityMask); //1 << iIdx1220 dw = SetThreadAffinityMask (pCtx->pSliceThreading->pThreadHandles[iIdx], dwAffinityMask); //1 << iIdx
1221 if (dw == 0) {1221 if (dw == 0) {
1222 str_t str[64] = {0};1222 char str[64] = {0};
1223 WelsSnprintf (str, 64, "SetThreadAffinityMask iIdx:%d", iIdx);1223 WelsSnprintf (str, 64, "SetThreadAffinityMask iIdx:%d", iIdx);
1224 }1224 }
1225 }1225 }

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t