diff --git a/src/uvw/util.h b/src/uvw/util.h index a6e4ffb3..efed2f46 100644 --- a/src/uvw/util.h +++ b/src/uvw/util.h @@ -250,14 +250,14 @@ namespace details { static constexpr std::size_t DEFAULT_SIZE = 128; template -std::string try_read(F &&f, Args &&...args) noexcept { +std::string try_read(F &&f, Args &&...args) { std::size_t size = DEFAULT_SIZE; char buf[DEFAULT_SIZE]; std::string str{}; auto err = std::forward(f)(args..., buf, &size); if(UV_ENOBUFS == err) { - std::unique_ptr data{new char[size]}; + auto data = std::make_unique(size); err = std::forward(f)(args..., data.get(), &size); if(0 == err) { @@ -424,7 +424,7 @@ struct utilities { * * @return The accessible subset of the password file entry. */ - static passwd_info passwd() noexcept; + static passwd_info passwd(); /** * @brief Retrieves the scheduling priority of a process.