Skip to content

Commit

Permalink
support VT_EMPTY by returning null - hopefully resolves naudio#1071
Browse files Browse the repository at this point in the history
  • Loading branch information
markheath committed Sep 20, 2023
1 parent b5d5ff8 commit 0036c73
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions NAudio.Wasapi/CoreAudioApi/PropVariant.cs
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,9 @@ public object Value
}
case VarEnum.VT_FILETIME:
return DateTime.FromFileTime((((long)filetime.dwHighDateTime) << 32) + filetime.dwLowDateTime);
case VarEnum.VT_EMPTY:
return null;
// I think VT_NULL means a database null, so could return DBNull.Value
}
throw new NotImplementedException("PropVariant " + ve);
}
Expand Down

0 comments on commit 0036c73

Please sign in to comment.