|
⇤ ← Revision 1 as of 2010-06-02 00:35:16
Size: 630
Comment: create page, add content (Wed Mar 10 ver; changeset 4428)
|
Size: 839
Comment: update content (old wiki)
|
| Deletions are marked like this. | Additions are marked like this. |
| Line 16: | Line 16: |
| ||'''sem'''||^a pointer to the SDL_sem structure to be destroyed^|| | ||'''sem'''||^a pointer to the SDL_sem structure / semaphore to be destroyed^|| |
| Line 20: | Line 20: |
| You can add your code example here | if (my_sem != NULL) { SDL_DestroySemaphore(my_sem); my_sem = NULL; } |
| Line 24: | Line 27: |
| ''You can add useful comments here'' | *<<BR>>It is not safe to destroy a semaphore if there are threads currently ,,blocked,, waiting on it. <<BR>>* |
| Line 27: | Line 30: |
| .[[SDL_CreateSemaphore]] ??? | .[[SDL_CreateSemaphore]] * <<Color2(green,The old wiki lists the other Sem functions as RFs.)>> |
DRAFT |
SDL_DestroySemaphore
Use this function to destroy a semaphore.
Syntax
void SDL_DestroySemaphore(SDL_sem* sem)
Function Parameters
sem |
a pointer to the SDL_sem structure / semaphore to be destroyed |
Code Examples
if (my_sem != NULL) {
SDL_DestroySemaphore(my_sem);
my_sem = NULL;
}
Remarks
*
It is not safe to destroy a semaphore if there are threads currently blocked waiting on it.
*
Related Functions
green
