Browse Source

修复视频文件不存在时,程序异常退出的问题

Suxue 1 year ago
parent
commit
24f2962475
2 changed files with 7 additions and 4 deletions
  1. 4 1
      WXUserReader.cs
  2. 3 3
      WechatBakTool.csproj

+ 4 - 1
WXUserReader.cs

@@ -368,7 +368,10 @@ namespace WechatBakTool
 
 
             if (path == null)
             if (path == null)
                 return null;
                 return null;
-            
+
+            if (!File.Exists(path))
+                return null;
+
             // 获取到原路径后,开始进行解密转移,只有图片和语音需要解密,解密后是直接归档目录
             // 获取到原路径后,开始进行解密转移,只有图片和语音需要解密,解密后是直接归档目录
             if(type == WXMsgType.Image || type== WXMsgType.Audio)
             if(type == WXMsgType.Image || type== WXMsgType.Audio)
             {
             {

+ 3 - 3
WechatBakTool.csproj

@@ -6,9 +6,9 @@
     <Nullable>enable</Nullable>
     <Nullable>enable</Nullable>
     <UseWPF>true</UseWPF>
     <UseWPF>true</UseWPF>
     <AllowUnsafeBlocks>True</AllowUnsafeBlocks>
     <AllowUnsafeBlocks>True</AllowUnsafeBlocks>
-    <AssemblyVersion>0.9.1.0</AssemblyVersion>
-    <FileVersion>0.9.1.0</FileVersion>
-    <Version>0.9.1.0</Version>
+    <AssemblyVersion>0.9.1.1</AssemblyVersion>
+    <FileVersion>0.9.1.1</FileVersion>
+    <Version>0.9.1.1</Version>
   </PropertyGroup>
   </PropertyGroup>
 
 
   <ItemGroup>
   <ItemGroup>