microsoft / microsoft/libHttpClient
XTaskQueueSetCurrentProcessTaskQueue SAL should use _In_opt_.
Open
Beginner friendly
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 295
- Forks
- 144
- Avg merge
- 2d 19h
- Merged PRs (30d)
- 2
Description
The SAL for XTaskQueueSetCurrentProcessTaskQueue is incorrect; it should be allowing a null parameter.
/// <summary>
/// Sets the given task queue as the process wide task queue. The
/// queue can be set to nullptr, in which case XTaskQueueGetCurrentProcessTaskQueue will
/// also return nullptr. The provided queue will have its handle duplicated
/// and any existing process task queue will have its handle closed.
/// </summary>
/// <param name='queue'>The queue to set up as the default task queue for the procces.</param>
STDAPI_(void) XTaskQueueSetCurrentProcessTaskQueue(
_In_ XTaskQueueHandle queue
) noexcept;
That should use _In_opt_.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start from the XTaskQueueSetCurrentProcessTaskQueue declaration shown in the issue and inspect the surrounding public API declarations. Update the queue parameter annotation to allow nullptr, then verify that the declaration matches the documented behavior and any related API checks.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- api
- Issue type
- Bug
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Quiet
- Clarity
- Clearly specified
- Newbie friendliness
- 65/100