Changeset 459
- Timestamp:
- 10/25/09 14:29:26 (4 weeks ago)
- Location:
- WizardsToolkit/trunk/wizard
- Files:
-
- 9 modified
-
blob.c (modified) (1 diff)
-
configure.c (modified) (9 diffs)
-
exception.c (modified) (8 diffs)
-
file.c (modified) (5 diffs)
-
log.c (modified) (18 diffs)
-
memory.c (modified) (9 diffs)
-
mime.c (modified) (9 diffs)
-
resource.c (modified) (14 diffs)
-
semaphore.h (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
WizardsToolkit/trunk/wizard/blob.c
r452 r459 329 329 blob_info->filename); 330 330 destroy=WizardFalse; 331 LockSemaphoreInfo(blob_info->semaphore);331 (void) LockSemaphoreInfo(blob_info->semaphore); 332 332 blob_info->reference_count--; 333 333 if (blob_info->reference_count == 0) 334 334 destroy=WizardTrue; 335 UnlockSemaphoreInfo(blob_info->semaphore);335 (void) UnlockSemaphoreInfo(blob_info->semaphore); 336 336 if (destroy == WizardFalse) 337 337 return(blob_info); -
WizardsToolkit/trunk/wizard/configure.c
r454 r459 163 163 if (configure_semaphore == (SemaphoreInfo *) NULL) 164 164 AcquireSemaphoreInfo(&configure_semaphore); 165 LockSemaphoreInfo(configure_semaphore);165 (void) LockSemaphoreInfo(configure_semaphore); 166 166 if (configure_list != (LinkedListInfo *) NULL) 167 167 configure_list=DestroyLinkedList(configure_list,DestroyConfigureElement); 168 168 configure_list=(LinkedListInfo *) NULL; 169 169 instantiate_configure=WizardFalse; 170 UnlockSemaphoreInfo(configure_semaphore);170 (void) UnlockSemaphoreInfo(configure_semaphore); 171 171 DestroySemaphoreInfo(&configure_semaphore); 172 172 } … … 256 256 Search for named configure. 257 257 */ 258 LockSemaphoreInfo(configure_semaphore);258 (void) LockSemaphoreInfo(configure_semaphore); 259 259 ResetLinkedListIterator(configure_list); 260 260 p=(const ConfigureInfo *) GetNextValueInLinkedList(configure_list); … … 271 271 (void) InsertValueInLinkedList(configure_list,0, 272 272 RemoveElementByValueFromLinkedList(configure_list,p)); 273 UnlockSemaphoreInfo(configure_semaphore);273 (void) UnlockSemaphoreInfo(configure_semaphore); 274 274 return(p); 275 275 } … … 355 355 Generate configure list. 356 356 */ 357 LockSemaphoreInfo(configure_semaphore);357 (void) LockSemaphoreInfo(configure_semaphore); 358 358 ResetLinkedListIterator(configure_list); 359 359 p=(const ConfigureInfo *) GetNextValueInLinkedList(configure_list); … … 365 365 p=(const ConfigureInfo *) GetNextValueInLinkedList(configure_list); 366 366 } 367 UnlockSemaphoreInfo(configure_semaphore);367 (void) UnlockSemaphoreInfo(configure_semaphore); 368 368 qsort((void *) options,(size_t) i,sizeof(*options),ConfigureInfoCompare); 369 369 options[i]=(ConfigureInfo *) NULL; … … 442 442 if (p == (const ConfigureInfo *) NULL) 443 443 return((char **) NULL); 444 LockSemaphoreInfo(configure_semaphore);445 UnlockSemaphoreInfo(configure_semaphore);444 (void) LockSemaphoreInfo(configure_semaphore); 445 (void) UnlockSemaphoreInfo(configure_semaphore); 446 446 options=(char **) AcquireQuantumMemory((size_t) 447 447 GetNumberOfElementsInLinkedList(configure_list)+1UL,sizeof(*options)); 448 448 if (options == (char **) NULL) 449 449 return((char **) NULL); 450 LockSemaphoreInfo(configure_semaphore);450 (void) LockSemaphoreInfo(configure_semaphore); 451 451 ResetLinkedListIterator(configure_list); 452 452 p=(const ConfigureInfo *) GetNextValueInLinkedList(configure_list); … … 458 458 p=(const ConfigureInfo *) GetNextValueInLinkedList(configure_list); 459 459 } 460 UnlockSemaphoreInfo(configure_semaphore);460 (void) UnlockSemaphoreInfo(configure_semaphore); 461 461 qsort((void *) options,(size_t) i,sizeof(*options),ConfigureCompare); 462 462 options[i]=(char *) NULL; … … 821 821 if (configure_semaphore == (SemephoreInfo *) NULL) 822 822 AcquireSemaphoreInfo(&configure_semaphore); 823 LockSemaphoreInfo(configure_semaphore);823 (void) LockSemaphoreInfo(configure_semaphore); 824 824 if ((configure_list == (LinkedListInfo *) NULL) && 825 825 (instantiate_configure == WizardFalse)) … … 828 828 instantiate_configure=WizardTrue; 829 829 } 830 UnlockSemaphoreInfo(configure_semaphore);830 (void) UnlockSemaphoreInfo(configure_semaphore); 831 831 } 832 832 return(configure_list != (LinkedListInfo *) NULL ? WizardTrue : WizardFalse); -
WizardsToolkit/trunk/wizard/exception.c
r452 r459 185 185 if (exception->exceptions == (void *) NULL) 186 186 return; 187 LockSemaphoreInfo(exception->semaphore);187 (void) LockSemaphoreInfo(exception->semaphore); 188 188 p=(ExceptionInfo *) RemoveLastElementFromLinkedList((LinkedListInfo *) 189 189 exception->exceptions); … … 197 197 exception->reason=(char *) NULL; 198 198 exception->description=(char *) NULL; 199 UnlockSemaphoreInfo(exception->semaphore);199 (void) UnlockSemaphoreInfo(exception->semaphore); 200 200 errno=0; 201 201 } … … 233 233 if (exception->exceptions == (void *) NULL) 234 234 return; 235 LockSemaphoreInfo(exception->semaphore);235 (void) LockSemaphoreInfo(exception->semaphore); 236 236 ResetLinkedListIterator((LinkedListInfo *) exception->exceptions); 237 237 p=(const ExceptionInfo *) GetNextValueInLinkedList((LinkedListInfo *) … … 248 248 exception->exceptions); 249 249 } 250 UnlockSemaphoreInfo(exception->semaphore);250 (void) UnlockSemaphoreInfo(exception->semaphore); 251 251 ClearWizardException(exception); 252 252 } … … 401 401 assert(exception != (ExceptionInfo *) NULL); 402 402 assert(exception->signature == WizardSignature); 403 LockSemaphoreInfo(exception->semaphore);403 (void) LockSemaphoreInfo(exception->semaphore); 404 404 exception->severity=UndefinedException; 405 405 if (exception->exceptions != (void *) NULL) … … 407 407 exception->exceptions,DestroyExceptionElement); 408 408 exception->signature=(~WizardSignature); 409 UnlockSemaphoreInfo(exception->semaphore);409 (void) UnlockSemaphoreInfo(exception->semaphore); 410 410 DestroySemaphoreInfo(&exception->semaphore); 411 411 if (exception->relinquish != WizardFalse) … … 663 663 if (relative->exceptions == (void *) NULL) 664 664 return; 665 LockSemaphoreInfo(exception->semaphore);665 (void) LockSemaphoreInfo(exception->semaphore); 666 666 ResetLinkedListIterator((LinkedListInfo *) relative->exceptions); 667 667 p=(const ExceptionInfo *) GetNextValueInLinkedList((LinkedListInfo *) … … 673 673 relative->exceptions); 674 674 } 675 UnlockSemaphoreInfo(exception->semaphore);675 (void) UnlockSemaphoreInfo(exception->semaphore); 676 676 } 677 677 -
WizardsToolkit/trunk/wizard/file.c
r452 r459 147 147 assert(file_info->signature == WizardSignature); 148 148 (void) LogWizardEvent(TraceEvent,GetWizardModule(),"%s",file_info->path); 149 LockSemaphoreInfo(file_info->semaphore);149 (void) LockSemaphoreInfo(file_info->semaphore); 150 150 path=AcquireString(file_info->path); 151 151 AppendFileExtension("lck",path); … … 176 176 { 177 177 path=DestroyString(path); 178 UnlockSemaphoreInfo(file_info->semaphore);178 (void) UnlockSemaphoreInfo(file_info->semaphore); 179 179 return(WizardTrue); 180 180 } … … 220 220 } 221 221 path=DestroyString(path); 222 UnlockSemaphoreInfo(file_info->semaphore);222 (void) UnlockSemaphoreInfo(file_info->semaphore); 223 223 return(WizardFalse); 224 224 } … … 433 433 assert(file_info->signature == WizardSignature); 434 434 (void) LogWizardEvent(TraceEvent,GetWizardModule(),"%s",file_info->path); 435 LockSemaphoreInfo(file_info->semaphore);435 (void) LockSemaphoreInfo(file_info->semaphore); 436 436 if (file_info->file >= 0) 437 437 if (close(file_info->file) == -1) … … 443 443 file_info->path=DestroyString(file_info->path); 444 444 file_info->signature=(~WizardSignature); 445 UnlockSemaphoreInfo(file_info->semaphore);445 (void) UnlockSemaphoreInfo(file_info->semaphore); 446 446 DestroySemaphoreInfo(&file_info->semaphore); 447 447 file_info=(FileInfo *) RelinquishWizardMemory(file_info); -
WizardsToolkit/trunk/wizard/log.c
r454 r459 226 226 log_info=(LogInfo *) GetLogInfo("*",exception); 227 227 exception=DestroyExceptionInfo(exception); 228 LockSemaphoreInfo(log_semaphore);228 (void) LockSemaphoreInfo(log_semaphore); 229 229 if (log_info->file != (FILE *) NULL) 230 230 { … … 234 234 log_info->file=(FILE *) NULL; 235 235 } 236 UnlockSemaphoreInfo(log_semaphore);236 (void) UnlockSemaphoreInfo(log_semaphore); 237 237 } 238 238 … … 280 280 Search for named log. 281 281 */ 282 LockSemaphoreInfo(log_semaphore);282 (void) LockSemaphoreInfo(log_semaphore); 283 283 ResetLinkedListIterator(log_list); 284 284 p=(const LogInfo *) GetNextValueInLinkedList(log_list); … … 295 295 (void) InsertValueInLinkedList(log_list,0, 296 296 RemoveElementByValueFromLinkedList(log_list,p)); 297 UnlockSemaphoreInfo(log_semaphore);297 (void) UnlockSemaphoreInfo(log_semaphore); 298 298 return(p); 299 299 } … … 376 376 Generate log list. 377 377 */ 378 LockSemaphoreInfo(log_semaphore);378 (void) LockSemaphoreInfo(log_semaphore); 379 379 ResetLinkedListIterator(log_list); 380 380 p=(const LogInfo *) GetNextValueInLinkedList(log_list); … … 386 386 p=(const LogInfo *) GetNextValueInLinkedList(log_list); 387 387 } 388 UnlockSemaphoreInfo(log_semaphore);388 (void) UnlockSemaphoreInfo(log_semaphore); 389 389 qsort((void *) preferences,(size_t) i,sizeof(*preferences),LogInfoCompare); 390 390 preferences[i]=(LogInfo *) NULL; … … 469 469 Generate log list. 470 470 */ 471 LockSemaphoreInfo(log_semaphore);471 (void) LockSemaphoreInfo(log_semaphore); 472 472 ResetLinkedListIterator(log_list); 473 473 p=(const LogInfo *) GetNextValueInLinkedList(log_list); … … 479 479 p=(const LogInfo *) GetNextValueInLinkedList(log_list); 480 480 } 481 UnlockSemaphoreInfo(log_semaphore);481 (void) UnlockSemaphoreInfo(log_semaphore); 482 482 qsort((void *) preferences,(size_t) i,sizeof(*preferences),LogCompare); 483 483 preferences[i]=(char *) NULL; … … 537 537 if (log_semaphore == (SemaphoreInfo *) NULL) 538 538 AcquireSemaphoreInfo(&log_semaphore); 539 LockSemaphoreInfo(log_semaphore);539 (void) LockSemaphoreInfo(log_semaphore); 540 540 if ((log_list == (LinkedListInfo *) NULL) && 541 541 (instantiate_log == WizardFalse)) … … 544 544 instantiate_log=WizardTrue; 545 545 } 546 UnlockSemaphoreInfo(log_semaphore);546 (void) UnlockSemaphoreInfo(log_semaphore); 547 547 } 548 548 return(log_list != (LinkedListInfo *) NULL ? WizardTrue : WizardFalse); … … 745 745 if (log_semaphore == (SemaphoreInfo *) NULL) 746 746 AcquireSemaphoreInfo(&log_semaphore); 747 LockSemaphoreInfo(log_semaphore);747 (void) LockSemaphoreInfo(log_semaphore); 748 748 if (log_list != (LinkedListInfo *) NULL) 749 749 log_list=DestroyLinkedList(log_list,DestroyLogElement); 750 750 instantiate_log=WizardFalse; 751 UnlockSemaphoreInfo(log_semaphore);751 (void) UnlockSemaphoreInfo(log_semaphore); 752 752 DestroySemaphoreInfo(&log_semaphore); 753 753 } … … 1134 1134 log_info=(LogInfo *) GetLogInfo("*",exception); 1135 1135 exception=DestroyExceptionInfo(exception); 1136 LockSemaphoreInfo(log_semaphore);1136 (void) LockSemaphoreInfo(log_semaphore); 1137 1137 if ((log_info->event_mask & type) == 0) 1138 1138 { 1139 UnlockSemaphoreInfo(log_semaphore);1139 (void) UnlockSemaphoreInfo(log_semaphore); 1140 1140 return(WizardTrue); 1141 1141 } … … 1152 1152 { 1153 1153 (void) ContinueTimer(log_info->timer); 1154 UnlockSemaphoreInfo(log_semaphore);1154 (void) UnlockSemaphoreInfo(log_semaphore); 1155 1155 return(WizardFalse); 1156 1156 } … … 1195 1195 { 1196 1196 (void) ContinueTimer(log_info->timer); 1197 UnlockSemaphoreInfo(log_semaphore);1197 (void) UnlockSemaphoreInfo(log_semaphore); 1198 1198 return(WizardFalse); 1199 1199 } … … 1203 1203 if (log_info->file == (FILE *) NULL) 1204 1204 { 1205 UnlockSemaphoreInfo(log_semaphore);1205 (void) UnlockSemaphoreInfo(log_semaphore); 1206 1206 return(WizardFalse); 1207 1207 } … … 1229 1229 text=(char *) RelinquishWizardMemory(text); 1230 1230 (void) ContinueTimer(log_info->timer); 1231 UnlockSemaphoreInfo(log_semaphore);1231 (void) UnlockSemaphoreInfo(log_semaphore); 1232 1232 return(WizardTrue); 1233 1233 } … … 1693 1693 exception=DestroyExceptionInfo(exception); 1694 1694 option=ParseWizardOption(WizardLogEventOptions,WizardTrue,events); 1695 LockSemaphoreInfo(log_semaphore);1695 (void) LockSemaphoreInfo(log_semaphore); 1696 1696 log_info=(LogInfo *) GetValueFromLinkedList(log_list,0); 1697 1697 log_info->event_mask=(LogEventType) option; 1698 1698 if (option == -1) 1699 1699 log_info->event_mask=UndefinedEvents; 1700 UnlockSemaphoreInfo(log_semaphore);1700 (void) UnlockSemaphoreInfo(log_semaphore); 1701 1701 return(log_info->event_mask); 1702 1702 } … … 1735 1735 log_info=(LogInfo *) GetLogInfo("*",exception); 1736 1736 exception=DestroyExceptionInfo(exception); 1737 LockSemaphoreInfo(log_semaphore);1737 (void) LockSemaphoreInfo(log_semaphore); 1738 1738 if (log_info->format != (char *) NULL) 1739 1739 log_info->format=DestroyString(log_info->format); 1740 1740 log_info->format=ConstantString(format); 1741 UnlockSemaphoreInfo(log_semaphore);1741 (void) UnlockSemaphoreInfo(log_semaphore); 1742 1742 } 1743 1743 -
WizardsToolkit/trunk/wizard/memory.c
r452 r459 391 391 if (free_segments == (DataSegmentInfo *) NULL) 392 392 { 393 LockSemaphoreInfo(memory_semaphore);393 (void) LockSemaphoreInfo(memory_semaphore); 394 394 if (free_segments == (DataSegmentInfo *) NULL) 395 395 { … … 411 411 free_segments=(&memory_info.segment_pool[0]); 412 412 } 413 UnlockSemaphoreInfo(memory_semaphore);414 } 415 LockSemaphoreInfo(memory_semaphore);413 (void) UnlockSemaphoreInfo(memory_semaphore); 414 } 415 (void) LockSemaphoreInfo(memory_semaphore); 416 416 memory=AcquireBlock(size == 0 ? 1UL : size); 417 417 if (memory == (void *) NULL) … … 420 420 memory=AcquireBlock(size == 0 ? 1UL : size); 421 421 } 422 UnlockSemaphoreInfo(memory_semaphore);422 (void) UnlockSemaphoreInfo(memory_semaphore); 423 423 #endif 424 424 return(memory); … … 546 546 i; 547 547 548 LockSemaphoreInfo(memory_semaphore);549 UnlockSemaphoreInfo(memory_semaphore);548 (void) LockSemaphoreInfo(memory_semaphore); 549 (void) UnlockSemaphoreInfo(memory_semaphore); 550 550 for (i=0; i < (long) memory_info.number_segments; i++) 551 551 if (memory_info.segments[i]->mapped == WizardFalse) … … 742 742 assert((SizeOfBlock(memory) % (4*sizeof(size_t))) == 0); 743 743 assert((*BlockHeader(NextBlock(memory)) & PreviousBlockBit) != 0); 744 LockSemaphoreInfo(memory_semaphore);744 (void) LockSemaphoreInfo(memory_semaphore); 745 745 if ((*BlockHeader(memory) & PreviousBlockBit) == 0) 746 746 { … … 773 773 *BlockHeader(NextBlock(memory))&=(~PreviousBlockBit); 774 774 InsertFreeBlock(memory,AllocationPolicy(SizeOfBlock(memory))); 775 UnlockSemaphoreInfo(memory_semaphore);775 (void) UnlockSemaphoreInfo(memory_semaphore); 776 776 #endif 777 777 return((void *) NULL); … … 870 870 memory=RelinquishWizardMemory(memory); 871 871 #else 872 LockSemaphoreInfo(memory_semaphore);872 (void) LockSemaphoreInfo(memory_semaphore); 873 873 block=ResizeBlock(memory,size == 0 ? 1UL : size); 874 874 if (block == (void *) NULL) … … 876 876 if (ExpandHeap(size == 0 ? 1UL : size) == WizardFalse) 877 877 { 878 UnlockSemaphoreInfo(memory_semaphore);878 (void) UnlockSemaphoreInfo(memory_semaphore); 879 879 memory=RelinquishWizardMemory(memory); 880 880 ThrowFatalException(ResourceLimitFatalError,"MemoryAllocationFailed"); … … 883 883 assert(block != (void *) NULL); 884 884 } 885 UnlockSemaphoreInfo(memory_semaphore);885 (void) UnlockSemaphoreInfo(memory_semaphore); 886 886 memory=RelinquishWizardMemory(memory); 887 887 #endif -
WizardsToolkit/trunk/wizard/mime.c
r454 r459 201 201 mime_info=(const MimeInfo *) NULL; 202 202 lsb_first=1; 203 LockSemaphoreInfo(mime_semaphore);203 (void) LockSemaphoreInfo(mime_semaphore); 204 204 ResetLinkedListIterator(mime_list); 205 205 p=(const MimeInfo *) GetNextValueInLinkedList(mime_list); … … 325 325 (void) InsertValueInLinkedList(mime_list,0, 326 326 RemoveElementByValueFromLinkedList(mime_list,p)); 327 UnlockSemaphoreInfo(mime_semaphore);327 (void) UnlockSemaphoreInfo(mime_semaphore); 328 328 return(mime_info); 329 329 } … … 409 409 Generate mime list. 410 410 */ 411 LockSemaphoreInfo(mime_semaphore);411 (void) LockSemaphoreInfo(mime_semaphore); 412 412 ResetLinkedListIterator(mime_list); 413 413 p=(const MimeInfo *) GetNextValueInLinkedList(mime_list); … … 419 419 p=(const MimeInfo *) GetNextValueInLinkedList(mime_list); 420 420 } 421 UnlockSemaphoreInfo(mime_semaphore);421 (void) UnlockSemaphoreInfo(mime_semaphore); 422 422 qsort((void *) aliases,(size_t) i,sizeof(*aliases),MimeInfoCompare); 423 423 aliases[i]=(MimeInfo *) NULL; … … 501 501 if (aliases == (char **) NULL) 502 502 return((char **) NULL); 503 LockSemaphoreInfo(mime_semaphore);503 (void) LockSemaphoreInfo(mime_semaphore); 504 504 ResetLinkedListIterator(mime_list); 505 505 p=(const MimeInfo *) GetNextValueInLinkedList(mime_list); … … 511 511 p=(const MimeInfo *) GetNextValueInLinkedList(mime_list); 512 512 } 513 UnlockSemaphoreInfo(mime_semaphore);513 (void) UnlockSemaphoreInfo(mime_semaphore); 514 514 qsort((void *) aliases,(size_t) i,sizeof(*aliases),MimeCompare); 515 515 aliases[i]=(char *) NULL; … … 607 607 if (mime_semaphore == (SemaphoreInfo *) NULL) 608 608 AcquireSemaphoreInfo(&mime_semaphore); 609 LockSemaphoreInfo(mime_semaphore);609 (void) LockSemaphoreInfo(mime_semaphore); 610 610 if ((mime_list == (LinkedListInfo *) NULL) && 611 611 (instantiate_mime == WizardFalse)) … … 614 614 instantiate_mime=WizardTrue; 615 615 } 616 UnlockSemaphoreInfo(mime_semaphore);616 (void) UnlockSemaphoreInfo(mime_semaphore); 617 617 } 618 618 return(mime_list != (LinkedListInfo *) NULL ? WizardTrue : WizardFalse); … … 1048 1048 if (mime_semaphore == (SemaphoreInfo *) NULL) 1049 1049 AcquireSemaphoreInfo(&mime_semaphore); 1050 LockSemaphoreInfo(mime_semaphore);1050 (void) LockSemaphoreInfo(mime_semaphore); 1051 1051 if (mime_list != (LinkedListInfo *) NULL) 1052 1052 mime_list=DestroyLinkedList(mime_list,DestroyMimeElement); 1053 1053 instantiate_mime=WizardFalse; 1054 UnlockSemaphoreInfo(mime_semaphore);1054 (void) UnlockSemaphoreInfo(mime_semaphore); 1055 1055 DestroySemaphoreInfo(&mime_semaphore); 1056 1056 } -
WizardsToolkit/trunk/wizard/resource.c
r452 r459 322 322 if (resource_semaphore == (SemaphoreInfo *) NULL) 323 323 AcquireSemaphoreInfo(&resource_semaphore); 324 LockSemaphoreInfo(resource_semaphore);324 (void) LockSemaphoreInfo(resource_semaphore); 325 325 if (temporary_resources == (SplayTreeInfo *) NULL) 326 326 temporary_resources=NewSplayTree(CompareSplayTreeString, 327 327 RelinquishWizardMemory,DestroyTemporaryResources); 328 UnlockSemaphoreInfo(resource_semaphore);328 (void) UnlockSemaphoreInfo(resource_semaphore); 329 329 resource=ConstantString(filename); 330 330 (void) AddValueToSplayTree(temporary_resources,resource,resource); … … 377 377 if (resource_semaphore == (SemaphoreInfo *) NULL) 378 378 AcquireSemaphoreInfo(&resource_semaphore); 379 LockSemaphoreInfo(resource_semaphore);379 (void) LockSemaphoreInfo(resource_semaphore); 380 380 switch (type) 381 381 { … … 443 443 break; 444 444 } 445 UnlockSemaphoreInfo(resource_semaphore);445 (void) UnlockSemaphoreInfo(resource_semaphore); 446 446 (void) LogWizardEvent(ResourceEvent,GetWizardModule(),"%s: %s/%s/%s", 447 447 WizardOptionToMnemonic(WizardResourceOptions,(long) type),resource_request, … … 521 521 if (resource_semaphore == (SemaphoreInfo *) NULL) 522 522 AcquireSemaphoreInfo(&resource_semaphore); 523 LockSemaphoreInfo(resource_semaphore);523 (void) LockSemaphoreInfo(resource_semaphore); 524 524 switch (type) 525 525 { … … 552 552 break; 553 553 } 554 UnlockSemaphoreInfo(resource_semaphore);554 (void) UnlockSemaphoreInfo(resource_semaphore); 555 555 return(resource); 556 556 } … … 586 586 if (resource_semaphore == (SemaphoreInfo *) NULL) 587 587 AcquireSemaphoreInfo(&resource_semaphore); 588 LockSemaphoreInfo(resource_semaphore);588 (void) LockSemaphoreInfo(resource_semaphore); 589 589 switch (type) 590 590 { … … 617 617 break; 618 618 } 619 UnlockSemaphoreInfo(resource_semaphore);619 (void) UnlockSemaphoreInfo(resource_semaphore); 620 620 return(resource); 621 621 } … … 659 659 if (resource_semaphore == (SemaphoreInfo *) NULL) 660 660 AcquireSemaphoreInfo(&resource_semaphore); 661 LockSemaphoreInfo(resource_semaphore);661 (void) LockSemaphoreInfo(resource_semaphore); 662 662 (void) FormatWizardSize(resource_info.area_limit,area_limit); 663 663 (void) FormatWizardSize(resource_info.disk_limit,disk_limit); … … 669 669 resource_info.file_limit,area_limit,memory_limit,map_limit,disk_limit); 670 670 (void) fflush(file); 671 UnlockSemaphoreInfo(resource_semaphore);671 (void) UnlockSemaphoreInfo(resource_semaphore); 672 672 return(WizardTrue); 673 673 } … … 709 709 if (resource_semaphore == (SemaphoreInfo *) NULL) 710 710 AcquireSemaphoreInfo(&resource_semaphore); 711 LockSemaphoreInfo(resource_semaphore);711 (void) LockSemaphoreInfo(resource_semaphore); 712 712 switch (type) 713 713 { … … 756 756 break; 757 757 } 758 UnlockSemaphoreInfo(resource_semaphore);758 (void) UnlockSemaphoreInfo(resource_semaphore); 759 759 (void) LogWizardEvent(ResourceEvent,GetWizardModule(),"%s: %s/%s/%s", 760 760 WizardOptionToMnemonic(WizardResourceOptions,(long) type),resource_request, … … 939 939 if (resource_semaphore == (SemaphoreInfo *) NULL) 940 940 AcquireSemaphoreInfo(&resource_semaphore); 941 LockSemaphoreInfo(resource_semaphore);941 (void) LockSemaphoreInfo(resource_semaphore); 942 942 if (temporary_resources != (SplayTreeInfo *) NULL) 943 943 temporary_resources=DestroySplayTree(temporary_resources); 944 UnlockSemaphoreInfo(resource_semaphore);944 (void) UnlockSemaphoreInfo(resource_semaphore); 945 945 DestroySemaphoreInfo(&resource_semaphore); 946 946 } … … 976 976 if (resource_semaphore == (SemaphoreInfo *) NULL) 977 977 AcquireSemaphoreInfo(&resource_semaphore); 978 LockSemaphoreInfo(resource_semaphore);978 (void) LockSemaphoreInfo(resource_semaphore); 979 979 switch (type) 980 980 { … … 1007 1007 break; 1008 1008 } 1009 UnlockSemaphoreInfo(resource_semaphore);1009 (void) UnlockSemaphoreInfo(resource_semaphore); 1010 1010 return(WizardTrue); 1011 1011 } -
WizardsToolkit/trunk/wizard/semaphore.h
r445 r459 36 36 37 37 extern WizardExport WizardBooleanType 38 LockSemaphoreInfo(SemaphoreInfo *),38 (void) LockSemaphoreInfo(SemaphoreInfo *), 39 39 SemaphoreComponentGenesis(void), 40 UnlockSemaphoreInfo(SemaphoreInfo *);40 (void) UnlockSemaphoreInfo(SemaphoreInfo *); 41 41 42 42 #if defined(__cplusplus) || defined(c_plusplus)
