updated build system
This commit is contained in:
@ -37,9 +37,7 @@ void smb_file::close() {
|
||||
|
||||
auto smb_file::copy_to(std::string_view new_path,
|
||||
bool overwrite) const -> bool {
|
||||
static constexpr const std::string_view function_name{
|
||||
static_cast<const char *>(__FUNCTION__),
|
||||
};
|
||||
REPERTORY_USES_FUNCTION_NAME();
|
||||
|
||||
try {
|
||||
if (not session_) {
|
||||
@ -61,9 +59,7 @@ auto smb_file::copy_to(std::string_view new_path,
|
||||
}
|
||||
|
||||
auto smb_file::exists() const -> bool {
|
||||
static constexpr const std::string_view function_name{
|
||||
static_cast<const char *>(__FUNCTION__),
|
||||
};
|
||||
REPERTORY_USES_FUNCTION_NAME();
|
||||
|
||||
try {
|
||||
if (not session_) {
|
||||
@ -90,9 +86,7 @@ auto smb_file::exists() const -> bool {
|
||||
}
|
||||
|
||||
void smb_file::flush() const {
|
||||
static constexpr const std::string_view function_name{
|
||||
static_cast<const char *>(__FUNCTION__),
|
||||
};
|
||||
REPERTORY_USES_FUNCTION_NAME();
|
||||
|
||||
try {
|
||||
throw std::runtime_error("failed to flush file|" + path_ +
|
||||
@ -106,9 +100,7 @@ void smb_file::flush() const {
|
||||
|
||||
auto smb_file::get_time(smb_session *session, smb_tid tid, std::string path,
|
||||
time_type type) -> std::optional<std::uint64_t> {
|
||||
static constexpr const std::string_view function_name{
|
||||
static_cast<const char *>(__FUNCTION__),
|
||||
};
|
||||
REPERTORY_USES_FUNCTION_NAME();
|
||||
|
||||
try {
|
||||
if (session == nullptr) {
|
||||
@ -147,9 +139,7 @@ auto smb_file::get_time(smb_session *session, smb_tid tid, std::string path,
|
||||
}
|
||||
|
||||
auto smb_file::is_symlink() const -> bool {
|
||||
static constexpr const std::string_view function_name{
|
||||
static_cast<const char *>(__FUNCTION__),
|
||||
};
|
||||
REPERTORY_USES_FUNCTION_NAME();
|
||||
|
||||
try {
|
||||
if (not session_) {
|
||||
@ -166,9 +156,7 @@ auto smb_file::is_symlink() const -> bool {
|
||||
}
|
||||
|
||||
auto smb_file::move_to(std::string_view new_path) -> bool {
|
||||
static constexpr const std::string_view function_name{
|
||||
static_cast<const char *>(__FUNCTION__),
|
||||
};
|
||||
REPERTORY_USES_FUNCTION_NAME();
|
||||
|
||||
try {
|
||||
if (utils::string::begins_with(new_path, "//")) {
|
||||
@ -218,9 +206,7 @@ auto smb_file::move_to(std::string_view new_path) -> bool {
|
||||
}
|
||||
|
||||
auto smb_file::open(bool read_only) -> bool {
|
||||
static constexpr const std::string_view function_name{
|
||||
static_cast<const char *>(__FUNCTION__),
|
||||
};
|
||||
REPERTORY_USES_FUNCTION_NAME();
|
||||
|
||||
try {
|
||||
if (fd_.has_value()) {
|
||||
@ -263,9 +249,7 @@ auto smb_file::open(bool read_only) -> bool {
|
||||
|
||||
auto smb_file::read(unsigned char *data, std::size_t to_read,
|
||||
std::uint64_t offset, std::size_t *total_read) -> bool {
|
||||
static constexpr const std::string_view function_name{
|
||||
static_cast<const char *>(__FUNCTION__),
|
||||
};
|
||||
REPERTORY_USES_FUNCTION_NAME();
|
||||
|
||||
try {
|
||||
if (total_read != nullptr) {
|
||||
@ -317,9 +301,7 @@ auto smb_file::read(unsigned char *data, std::size_t to_read,
|
||||
}
|
||||
|
||||
auto smb_file::remove() -> bool {
|
||||
static constexpr const std::string_view function_name{
|
||||
static_cast<const char *>(__FUNCTION__),
|
||||
};
|
||||
REPERTORY_USES_FUNCTION_NAME();
|
||||
|
||||
try {
|
||||
if (not exists()) {
|
||||
@ -364,9 +346,7 @@ auto smb_file::remove() -> bool {
|
||||
}
|
||||
|
||||
auto smb_file::size() const -> std::optional<std::uint64_t> {
|
||||
static constexpr const std::string_view function_name{
|
||||
static_cast<const char *>(__FUNCTION__),
|
||||
};
|
||||
REPERTORY_USES_FUNCTION_NAME();
|
||||
|
||||
try {
|
||||
if (not session_) {
|
||||
@ -393,9 +373,7 @@ auto smb_file::size() const -> std::optional<std::uint64_t> {
|
||||
}
|
||||
|
||||
auto smb_file::truncate(std::size_t size) -> bool {
|
||||
static constexpr const std::string_view function_name{
|
||||
static_cast<const char *>(__FUNCTION__),
|
||||
};
|
||||
REPERTORY_USES_FUNCTION_NAME();
|
||||
|
||||
try {
|
||||
throw std::runtime_error("failed to truncate file|" + path_ + '|' +
|
||||
@ -411,9 +389,7 @@ auto smb_file::truncate(std::size_t size) -> bool {
|
||||
|
||||
auto smb_file::write(const unsigned char *data, std::size_t to_write,
|
||||
std::size_t offset, std::size_t *total_written) -> bool {
|
||||
static constexpr const std::string_view function_name{
|
||||
static_cast<const char *>(__FUNCTION__),
|
||||
};
|
||||
REPERTORY_USES_FUNCTION_NAME();
|
||||
|
||||
try {
|
||||
if (total_written != nullptr) {
|
||||
|
Reference in New Issue
Block a user