From d129f3757af10bb5c61bac635613e3a59c46a3b0 Mon Sep 17 00:00:00 2001 From: James King Date: Fri, 7 Jul 2017 15:42:54 +0100 Subject: [PATCH] Added an exception when attempting to write to a shared file --- Facepunch.Steamworks/Client/RemoteStorage.File.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Facepunch.Steamworks/Client/RemoteStorage.File.cs b/Facepunch.Steamworks/Client/RemoteStorage.File.cs index d554afe..3cac8c8 100644 --- a/Facepunch.Steamworks/Client/RemoteStorage.File.cs +++ b/Facepunch.Steamworks/Client/RemoteStorage.File.cs @@ -109,6 +109,8 @@ namespace Facepunch.Steamworks /// public RemoteFileWriteStream OpenWrite() { + if (_isUgc) throw new InvalidOperationException("Cannot write to a shared file."); + return new RemoteFileWriteStream( remoteStorage, this ); }