From 3fd637e44ce3c50206f1ea97c8ec17afd98a498e Mon Sep 17 00:00:00 2001 From: Ibrahim Islam Date: Tue, 20 Oct 2020 06:31:01 +0700 Subject: [PATCH 1/3] shortens unique id generation Former-commit-id: 577776f30fff0afc8d157dce914040dd8a1c1b28 --- FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs b/FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs index 7e79f55..df7729d 100644 --- a/FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs +++ b/FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs @@ -8,7 +8,7 @@ static class PipeHelpers { static readonly string PipePrefix = Path.Combine(Path.GetTempPath(), "CoreFxPipe_"); - public static string GetUnqiuePipeName() => "FFMpegCore_" + Guid.NewGuid(); + public static string GetUnqiuePipeName() => "FFMpegCore_" + Guid.NewGuid("N").Substring(0, 5); public static string GetPipePath(string pipeName) { From a7c7eb48723e565a974f87dc808708da6951c3ff Mon Sep 17 00:00:00 2001 From: Ibrahim Islam Date: Tue, 20 Oct 2020 06:35:51 +0700 Subject: [PATCH 2/3] refactors to use string interpolation Former-commit-id: 462069cefe0555d14bca8effd4fb205799f5fa7c --- FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs b/FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs index df7729d..67c59bf 100644 --- a/FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs +++ b/FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs @@ -8,7 +8,7 @@ static class PipeHelpers { static readonly string PipePrefix = Path.Combine(Path.GetTempPath(), "CoreFxPipe_"); - public static string GetUnqiuePipeName() => "FFMpegCore_" + Guid.NewGuid("N").Substring(0, 5); + public static string GetUnqiuePipeName() => $"FFMpegCore_{Guid.NewGuid("N").Substring(0, 5)}"; public static string GetPipePath(string pipeName) { From d2691b6f1f50f5c40685ba1c2a5bf2382d8dc9f4 Mon Sep 17 00:00:00 2001 From: Ibrahim Islam Date: Tue, 20 Oct 2020 06:53:24 +0700 Subject: [PATCH 3/3] fixes typo Former-commit-id: fc988b3bbe75b32d20aff1700dd2d1cc25e4fb17 --- FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs b/FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs index 67c59bf..2b4feed 100644 --- a/FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs +++ b/FFMpegCore/FFMpeg/Pipes/PipeHelpers.cs @@ -8,7 +8,7 @@ static class PipeHelpers { static readonly string PipePrefix = Path.Combine(Path.GetTempPath(), "CoreFxPipe_"); - public static string GetUnqiuePipeName() => $"FFMpegCore_{Guid.NewGuid("N").Substring(0, 5)}"; + public static string GetUnqiuePipeName() => $"FFMpegCore_{Guid.NewGuid().ToString("N").Substring(0, 5)}"; public static string GetPipePath(string pipeName) {