You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When subscribing to service creation via AdvApi32.NotifyServiceStatusChange and AdvApi32.SERVICE_NOTIFY_FLAGS.SERVICE_NOTIFY_CREATED the returning structures pszServiceNames contains a false-positive IsNullOrEmpty even though the value is neither null nor empty. The IsNull check is okay, it returns false. But the check for string.Empty returns true, which leads to the false-positive. Checking for IsNull, then retrieving the string and checking the returned string for string.Empty myself gives the desired result.
Describe the bug and how to reproduce
When subscribing to service creation via
AdvApi32.NotifyServiceStatusChange
andAdvApi32.SERVICE_NOTIFY_FLAGS.SERVICE_NOTIFY_CREATED
the returning structurespszServiceNames
contains a false-positiveIsNullOrEmpty
even though the value is neither null nor empty. TheIsNull
check is okay, it returnsfalse
. But the check forstring.Empty
returnstrue
, which leads to the false-positive. Checking forIsNull
, then retrieving the string and checking the returned string forstring.Empty
myself gives the desired result.What code is involved
Expected behavior
Returning
false
on non-empty values.The text was updated successfully, but these errors were encountered: