diff options
author | Maxim Pimenov <m@maps.me> | 2018-06-13 17:00:42 +0300 |
---|---|---|
committer | Arsentiy Milchakov <milcars@mapswithme.com> | 2018-06-14 15:42:53 +0300 |
commit | d2106d6ecfb2f796601a8a6de6f57926fd9d3fd5 (patch) | |
tree | 1353201631064eeeb3fceaa174015528584dc449 /ugc | |
parent | da629a335d865757bde638a812575d8b35f07b83 (diff) |
[coding] Exceptions in FileReader are now thrown in places where they were being caught.
Defaulting withExceptions to false in FileReader looks like a bad idea
since most clients seem to be expecting it to default to true.
This CL only corrects the behaviour so that it suits clients' expectations better.
Diffstat (limited to 'ugc')
-rw-r--r-- | ugc/storage.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ugc/storage.cpp b/ugc/storage.cpp index f602560c21..6d49985487 100644 --- a/ugc/storage.cpp +++ b/ugc/storage.cpp @@ -194,7 +194,7 @@ void Storage::Load() auto const indexFilePath = GetIndexFilePath(); try { - FileReader r(indexFilePath); + FileReader r(indexFilePath, true /* with exceptions */); r.ReadAsString(data); } catch (FileReader::Exception const & exception) @@ -424,7 +424,7 @@ size_t GetNumberOfUnsentUGC() string data; try { - FileReader r(indexFilePath); + FileReader r(indexFilePath, true /* with exceptions */); r.ReadAsString(data); } catch (FileReader::Exception const & exception) |