From fee7d6f4500849403a75fe2dbcb5a132b7bbfcc9 Mon Sep 17 00:00:00 2001 From: Malte Rosenbjerg Date: Sat, 24 Oct 2020 22:17:33 +0200 Subject: [PATCH] Fix unix socket naming Former-commit-id: 3d50530c742bd5c3de39d6264a86f41b62ee1001 --- FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs b/FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs index 2b4feed..4f07720 100644 --- a/FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs +++ b/FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs @@ -6,16 +6,14 @@ namespace FFMpegCore.Pipes { static class PipeHelpers { - static readonly string PipePrefix = Path.Combine(Path.GetTempPath(), "CoreFxPipe_"); - - public static string GetUnqiuePipeName() => $"FFMpegCore_{Guid.NewGuid().ToString("N").Substring(0, 5)}"; + public static string GetUnqiuePipeName() => $"FFMpegCore_{Guid.NewGuid()}"; public static string GetPipePath(string pipeName) { if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows)) return $@"\\.\pipe\{pipeName}"; else - return $"unix:{PipePrefix}{pipeName}"; // dotnet uses unix sockets on unix, for more see https://github.com/dotnet/runtime/issues/24390 + return $"unix:/run/CoreFxPipe_{pipeName}"; } } }