From 26e09474a95cfec1cdf718c033b80baf819e6f8f Mon Sep 17 00:00:00 2001
From: jduncanator <jduncanator@users.noreply.github.com>
Date: Mon, 19 Nov 2018 11:20:17 +1100
Subject: ContentServices: Handle null LocationEntry Path in VerifyContentType
 (#506)

When `LocationEntry.ContentPath` is `null`, we can always return `false` as it can't possibly be a valid `ContentType`
---
 Ryujinx.HLE/FileSystem/Content/ContentManager.cs | 5 +++++
 1 file changed, 5 insertions(+)

(limited to 'Ryujinx.HLE/FileSystem/Content/ContentManager.cs')

diff --git a/Ryujinx.HLE/FileSystem/Content/ContentManager.cs b/Ryujinx.HLE/FileSystem/Content/ContentManager.cs
index 025eb261..3727841d 100644
--- a/Ryujinx.HLE/FileSystem/Content/ContentManager.cs
+++ b/Ryujinx.HLE/FileSystem/Content/ContentManager.cs
@@ -223,6 +223,11 @@ namespace Ryujinx.HLE.FileSystem.Content
 
         private bool VerifyContentType(LocationEntry LocationEntry, ContentType ContentType)
         {
+            if (LocationEntry.ContentPath == null)
+            {
+                return false;
+            }
+
             StorageId StorageId     = LocationHelper.GetStorageId(LocationEntry.ContentPath);
             string    InstalledPath = Device.FileSystem.SwitchPathToSystemPath(LocationEntry.ContentPath);
 
-- 
cgit v1.2.3-70-g09d2