Skip to content

Commit

Permalink
Fix read of NodeId attribute AccessRestrictions by casting return typ…
Browse files Browse the repository at this point in the history
…e from Enum to ushort (#2883)

In the read NodeId servcie call an enum is by default cast to Int32, so the cast to ushort is needed here to return the expected type for the AccessRestrictions.
  • Loading branch information
romanett authored Dec 5, 2024
1 parent 6c62eb2 commit 67a0df1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Stack/Opc.Ua.Core/Stack/State/NodeState.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3669,7 +3669,7 @@ protected virtual ServiceResult ReadNonValueAttribute(

if (ServiceResult.IsGood(result))
{
value = accessRestrictions;
value = (ushort)accessRestrictions;
}

if (value != null || result != null)
Expand Down

0 comments on commit 67a0df1

Please sign in to comment.