AlexanderKaraberov opened a new pull request #1164: Fix: Proper error handling 
for file:open() call in couch_file.erl
URL: https://github.com/apache/couchdb/pull/1164
 
 
   ## Overview
   
   According to Erlang's 
[file:open](http://erlang.org/doc/man/file.html#open-2) docs this function 
returns `{error, Reason}` in case of failure but inside `couch_file:sync` and 
`init` functions there are no checks for this in two places. Consequently when 
I received `{error, emfile}` kind of error, process crashed with `badmatch` 
instead of a proper error.
   
   ## Testing recommendations
   
   Simulate `{error, emfile}` conditions (e.g. decrease `ulimit` on your OS) 
and observe an error.
   
   ## Checklist
   
   - [ ] Code is written and works correctly;
   - [ ] Changes are covered by tests;
   - [ ] Documentation reflects the changes;
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to