Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix ReadCertPool function #46

Merged
merged 1 commit into from
Dec 12, 2018
Merged

fix ReadCertPool function #46

merged 1 commit into from
Dec 12, 2018

Conversation

dopey
Copy link
Contributor

@dopey dopey commented Dec 12, 2018

  • document acceptable input
  • don't fail if input is not either a file or directory
  • trim space in comma delineated file list

* document acceptable input
* don't fail if input is not either a file or directory
* trim space in comma delineated file list
@dopey dopey requested a review from maraino December 12, 2018 00:38
@codecov
Copy link

codecov bot commented Dec 12, 2018

Codecov Report

Merging #46 into master will decrease coverage by 0.02%.
The diff coverage is 0%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master     #46      +/-   ##
=========================================
- Coverage   70.12%   70.1%   -0.03%     
=========================================
  Files          47      47              
  Lines        6498    6500       +2     
=========================================
  Hits         4557    4557              
- Misses       1590    1592       +2     
  Partials      351     351
Impacted Files Coverage Δ
crypto/x509util/crt.go 0% <0%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a633fd7...09d47c4. Read the comment docs.

1 similar comment
@codecov
Copy link

codecov bot commented Dec 12, 2018

Codecov Report

Merging #46 into master will decrease coverage by 0.02%.
The diff coverage is 0%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master     #46      +/-   ##
=========================================
- Coverage   70.12%   70.1%   -0.03%     
=========================================
  Files          47      47              
  Lines        6498    6500       +2     
=========================================
  Hits         4557    4557              
- Misses       1590    1592       +2     
  Partials      351     351
Impacted Files Coverage Δ
crypto/x509util/crt.go 0% <0%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a633fd7...09d47c4. Read the comment docs.

if err != nil {
return nil, errors.WithStack(err)
if err != nil && !os.IsNotExist(err) {
return nil, errors.Wrapf(err, "os.Stat %s failed", path)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What happens if it's a not exists error? This snippet will show a nice error:

if err != nil {
        return nil, errs.FileError(err, path)
}

@dopey dopey merged commit 09d47c4 into master Dec 12, 2018
@dopey dopey deleted the pool branch December 12, 2018 04:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants