Skip to content

Commit

Permalink
Try fixing build with gcc 13.3 (SoftFever/OrcaSlicer#5991) (SoftFever…
Browse files Browse the repository at this point in the history
…/OrcaSlicer#5992)

(cherry picked from commit adec6b7ebdd91a71c61505dd4e1cc5ee9e17afcc)
  • Loading branch information
Noisyfox authored and Ocraftyone committed Jul 22, 2024
1 parent e74bdc2 commit e4c2a7f
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/slic3r/Utils/Http.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -135,9 +135,13 @@ std::unique_ptr<CurlGlobalInit> CurlGlobalInit::instance;

struct form_file
{
fs::ifstream ifs;
fs::ifstream ifs;
boost::filesystem::ifstream::off_type init_offset;
size_t content_length;

form_file(fs::path const& p, const boost::filesystem::ifstream::off_type offset, const size_t content_length)
: ifs(p, std::ios::in | std::ios::binary), init_offset(offset), content_length(content_length)
{}
};

struct Http::priv
Expand Down Expand Up @@ -327,7 +331,7 @@ void Http::priv::form_add_file(const char *name, const fs::path &path, const cha
filename = path.string().c_str();
}

form_files.emplace_back(form_file{{path, std::ios::in | std::ios::binary}, offset, length});
form_files.emplace_back(path, offset, length);
auto &f = form_files.back();
size_t size = length;
if (length == 0) {
Expand Down

0 comments on commit e4c2a7f

Please sign in to comment.