Skip to content
Closed
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
14 changes: 14 additions & 0 deletions libutils/file_lib.c
Original file line number Diff line number Diff line change
Expand Up @@ -1569,6 +1569,19 @@ SMART_SYSCALLS_UNUSED static bool FileSparseCopyShoveling(int sd, const char *sr
assert(total_bytes_written != NULL);
assert(last_write_was_a_hole != NULL);

Log(LOG_LEVEL_INFO, "ENT-13508: Debugging HP-UX is always a joy :)");

struct stat sb;
if (fstat(sd, &sb) == -1) {
Log(LOG_LEVEL_ERR, "ENT-13508: fstat on source %s: %s", dst_name, GetErrorStr());
}
Log(LOG_LEVEL_INFO, "ENT-13508: fstat on source %s = %jd Bytes", dst_name, (intmax_t)sb.st_size);

if (fstat(dd, &sb) == -1) {
Log(LOG_LEVEL_ERR, "ENT-13508: fstat on dest %s: %s", dst_name, GetErrorStr());
}
Log(LOG_LEVEL_INFO, "ENT-13508: fstat on dest %s = %jd Bytes", dst_name, (intmax_t)sb.st_size);

const size_t buf_size = blk_size;
void *buf = xmalloc(buf_size);

Expand Down Expand Up @@ -1606,6 +1619,7 @@ SMART_SYSCALLS_UNUSED static bool FileSparseCopyShoveling(int sd, const char *sr
}

free(buf);
Log(LOG_LEVEL_INFO, "ENT-13508: Total read from %s is %zu Bytes", src_name, n_read_total);
*total_bytes_written = n_read_total;
return retval;
}
Expand Down
36 changes: 0 additions & 36 deletions tests/unit/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -46,42 +46,6 @@ libtest_la_SOURCES = cmockery.c cmockery.h schema.h test.c test.h
libtest_la_LIBADD = ../../libutils/libutils.la ../../libcompat/libcompat.la $(PCRE_LIBS) $(OPENSSL_LIBS) $(SYSTEMD_LOGGING_LIBS) $(LIBYAML_LIBS)

check_PROGRAMS = \
cleanup_test \
condition_macros_test \
csv_writer_test \
set_test \
csv_parser_test \
env_file_test \
alloc_test \
string_writer_test \
file_writer_test \
fsattrs_test \
xml_writer_test \
sequence_test \
json_test \
misc_lib_test \
string_lib_test \
thread_test \
file_lib_test \
file_lock_test \
map_test \
path_test \
logging_timestamp_test \
refcount_test \
list_test \
buffer_test \
ipaddress_test \
rb-tree-test \
queue_test \
stack_test \
threaded_queue_test \
threaded_deque_test \
threaded_stack_test \
version_comparison_test \
ring_buffer_test \
libcompat_test \
definitions_test \
glob_lib_test \
string_sequence_test

if WITH_PCRE2
Expand Down
Loading