ソースを参照

Fix: Add nullptr check

lessone1 1 年間 前
コミット
170796ea70
1 ファイル変更5 行追加0 行削除
  1. 5 0
      src/wn_utils.c

+ 5 - 0
src/wn_utils.c

@@ -279,6 +279,11 @@ int urldecode(char *str, int len)
     int value;
     int value;
     int c;
     int c;
 
 
+    if (data == RT_NULL)
+    {
+        return 0;
+    }
+
     while (len--)
     while (len--)
     {
     {
         if (*data == '+')
         if (*data == '+')