Skip to content

Commit

Permalink
warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
barncastle committed Jul 13, 2018
1 parent 308a31b commit f4a6dfc
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
2 changes: 2 additions & 0 deletions WDBXEditor/Forms/LegionParser.cs
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ private void Parse(MemoryStream stream, string file)
ParseWDC1(stream, file);
return;

#pragma warning disable CS0162 // Unreachable code detected
stream.Position = 0;

using (var dbReader = new BinaryReader(stream, Encoding.UTF8))
Expand Down Expand Up @@ -280,6 +281,7 @@ private void Parse(MemoryStream stream, string file)
tables.Add(table);
Database.ForceGC();
}
#pragma warning restore CS0162 // Unreachable code detected
}


Expand Down
2 changes: 1 addition & 1 deletion WDBXEditor/Storage/DBEntry.cs
Original file line number Diff line number Diff line change
Expand Up @@ -749,7 +749,7 @@ public bool ImportCSV(string filename, bool headerrow, UpdateMode mode, out stri
}
}
}
catch (FormatException ex)
catch (FormatException)
{
error = $"Mismatch of data to datatype in row index {usedids.Count + 1}";
return false;
Expand Down
4 changes: 2 additions & 2 deletions WDBXEditor/Storage/Database.cs
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ public static async Task<List<string>> LoadFiles(IEnumerable<string> filenames)
_errors.Add(FormatError(file, ErrorType.Warning, reader.ErrorMessage));
}
}
catch (ConstraintException ex) { _errors.Add(FormatError(file, ErrorType.Error, "Id column contains duplicates.")); }
catch (ConstraintException) { _errors.Add(FormatError(file, ErrorType.Error, "Id column contains duplicates.")); }
catch (Exception ex) { _errors.Add(FormatError(file, ErrorType.Error, ex.Message)); }
}

Expand Down Expand Up @@ -107,7 +107,7 @@ public static async Task<List<string>> LoadFiles(ConcurrentDictionary<string, Me
_errors.Add(FormatError(s.Key, ErrorType.Warning, reader.ErrorMessage));
}
}
catch (ConstraintException ex)
catch (ConstraintException)
{
_errors.Add(FormatError(s.Key, ErrorType.Error, "Id column contains duplicates."));
}
Expand Down
2 changes: 1 addition & 1 deletion WDBXEditor/Storage/Definition.cs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ string ValidFilename(string b)
_loading = false;
return true;
}
catch (Exception ex)
catch (Exception)
{
_loading = false;
return false;
Expand Down

0 comments on commit f4a6dfc

Please sign in to comment.