CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Jan 2006
    Posts
    326

    Using semaphore with task

    We know that semaphore limits the number of threads that can access a resource or pool of resources concurrently.
    For this example at http://msdn.microsoft.com/en-us/libr...v=vs.110).aspx
    It uses threads, my question is if we replace threads with tasks, can we still use semaphore?

  2. #2
    Arjay's Avatar
    Arjay is offline Moderator / EX MS MVP Power Poster
    Join Date
    Aug 2004
    Posts
    13,490

    Re: Using semaphore with task

    Yes, as semaphores aren't tied to threads.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured