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 signed/unsigned mismatch in VS #1970

Merged
merged 1 commit into from
Jun 13, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
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
2 changes: 1 addition & 1 deletion include/spdlog/async.h
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ struct async_factory_impl
auto tp = registry_inst.get_tp();
if (tp == nullptr)
{
tp = std::make_shared<details::thread_pool>(details::default_async_q_size, 1);
tp = std::make_shared<details::thread_pool>(details::default_async_q_size, 1U);
registry_inst.set_tp(tp);
}

Expand Down
2 changes: 1 addition & 1 deletion include/spdlog/details/file_helper.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ class SPDLOG_API file_helper

private:
const int open_tries_ = 5;
const int open_interval_ = 10;
const unsigned int open_interval_ = 10;
std::FILE *fd_{nullptr};
filename_t filename_;
};
Expand Down
2 changes: 1 addition & 1 deletion include/spdlog/details/os-inl.h
Original file line number Diff line number Diff line change
Expand Up @@ -366,7 +366,7 @@ SPDLOG_INLINE size_t thread_id() SPDLOG_NOEXCEPT

// This is avoid msvc issue in sleep_for that happens if the clock changes.
// See https://github.com/gabime/spdlog/issues/609
SPDLOG_INLINE void sleep_for_millis(int milliseconds) SPDLOG_NOEXCEPT
SPDLOG_INLINE void sleep_for_millis(unsigned int milliseconds) SPDLOG_NOEXCEPT
{
#if defined(_WIN32)
::Sleep(milliseconds);
Expand Down
2 changes: 1 addition & 1 deletion include/spdlog/details/os.h
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ SPDLOG_API size_t thread_id() SPDLOG_NOEXCEPT;

// This is avoid msvc issue in sleep_for that happens if the clock changes.
// See https://github.com/gabime/spdlog/issues/609
SPDLOG_API void sleep_for_millis(int milliseconds) SPDLOG_NOEXCEPT;
SPDLOG_API void sleep_for_millis(unsigned int milliseconds) SPDLOG_NOEXCEPT;

SPDLOG_API std::string filename_to_str(const filename_t &filename);

Expand Down