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

Splunkent client refactor #27205

Merged
merged 28 commits into from
Oct 16, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
removed defer calls in loop
  • Loading branch information
shalper2 committed Oct 16, 2023
commit 463eb1068194eb0fa2f3a63595ccea2a5280b643
4 changes: 1 addition & 3 deletions receiver/splunkenterprisereceiver/scraper.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"encoding/json"
"encoding/xml"
"errors"
"fmt"
"fmt"
"io"
"net/http"
"strconv"
Expand Down Expand Up @@ -100,13 +100,11 @@ func (s *splunkScraper) scrapeLicenseUsageByIndex(ctx context.Context, now pcomm
errs.Add(err)
return
}
defer res.Body.Close()

// if its a 204 the body will be empty because we are still waiting on search results
err = unmarshallSearchReq(res, &sr)
if err != nil {
errs.Add(err)
return
}
res.Body.Close()

Expand Down