From 51d71c226be424b6a698c7474d237e8c69661af5 Mon Sep 17 00:00:00 2001 From: Chris Koeritz Date: Thu, 20 Sep 2012 14:45:25 -0400 Subject: [PATCH] cleaned out idiotic commenting of FUNCDEF, which had been done when a strict compile mode complained about the unused ones, but that was aggravating; we want the FUNCDEF to be available anywhere, regardless of whether debugging is using it or not. --- .../bookmark_tools/bookmark_tree.cpp | 4 ++-- .../bookmark_tools/js_marks_maker.cpp | 6 +++--- nucleus/applications/bundler/bundle_creator.cpp | 8 ++++---- nucleus/applications/bundler/common_bundle.cpp | 8 ++++---- nucleus/library/application/command_line.cpp | 2 +- nucleus/library/application/launch_manager.cpp | 4 ++-- nucleus/library/application/redirecter.cpp | 6 +++--- nucleus/library/application/shared_memory.cpp | 2 +- .../configuration/application_configuration.cpp | 4 ++-- .../library/configuration/ini_configurator.cpp | 4 ++-- nucleus/library/configuration/system_values.cpp | 4 ++-- .../library/configuration/table_configurator.cpp | 4 ++-- nucleus/library/filesystem/directory_tree.cpp | 13 ++++++++++++- nucleus/library/filesystem/filename.cpp | 2 +- nucleus/library/filesystem/filename.h | 6 ++++-- nucleus/library/filesystem/heavy_file_ops.cpp | 15 +++++++++------ nucleus/library/filesystem/heavy_file_ops.h | 1 + nucleus/library/filesystem/huge_file.cpp | 4 ++-- nucleus/library/nodes/packable_tree.cpp | 10 +++++----- .../processes/configured_applications.cpp | 12 ++++++------ nucleus/library/processes/ethread.cpp | 8 ++++---- nucleus/library/processes/process_control.cpp | 2 +- nucleus/library/structures/memory_limiter.cpp | 2 +- nucleus/library/tests_basis/test_string.cpp | 14 +++++++------- .../library/tests_filesystem/test_byte_filer.cpp | 2 +- .../tests_filesystem/test_directory_tree.cpp | 4 ++-- .../library/tests_filesystem/test_filename.cpp | 10 +++++----- nucleus/library/versions/version_ini.cpp | 4 ++-- nucleus/tools/clam_tools/version_stamper.cpp | 2 +- nucleus/tools/clam_tools/vsts_version_fixer.cpp | 8 ++++---- nucleus/tools/clam_tools/write_build_config.cpp | 2 +- nucleus/tools/simple_utilities/create_guid.cpp | 2 +- octopi/applications/transporter/synch_files.cpp | 2 +- octopi/library/cromp/cromp_client.cpp | 6 +++--- octopi/library/cromp/cromp_common.cpp | 8 ++++---- octopi/library/cromp/cromp_server.cpp | 16 ++++++++-------- octopi/library/octopus/entity_data_bin.cpp | 14 ++++++-------- octopi/library/octopus/infoton.cpp | 12 ++++++------ octopi/library/octopus/octopus.cpp | 4 ++-- octopi/library/sockets/internet_address.cpp | 4 ++-- octopi/library/sockets/raw_socket.cpp | 2 +- octopi/library/sockets/socket_minder.cpp | 4 ++-- octopi/library/sockets/tcpip_stack.cpp | 6 +++--- octopi/library/synchronic/list_manager.cpp | 2 +- octopi/library/tentacles/encryption_infoton.cpp | 4 ++-- .../library/tentacles/file_transfer_tentacle.cpp | 4 ++-- octopi/library/tentacles/login_tentacle.cpp | 2 +- 47 files changed, 142 insertions(+), 127 deletions(-) diff --git a/nucleus/applications/bookmark_tools/bookmark_tree.cpp b/nucleus/applications/bookmark_tools/bookmark_tree.cpp index c8fc1f55..04dd9d5f 100644 --- a/nucleus/applications/bookmark_tools/bookmark_tree.cpp +++ b/nucleus/applications/bookmark_tools/bookmark_tree.cpp @@ -135,7 +135,7 @@ inner_mark_tree &bookmark_tree::access_root() { return *_mark_tree; } bool bookmark_tree::magic_category_comparison(const astring &a, const astring &b) { -// FUNCDEF("magic_category_comparison"); + FUNCDEF("magic_category_comparison"); //LOG(astring("compare: a=") + a + " b=" + b); if (a.iequals(b)) return true; astring a_name, a_nick; @@ -409,7 +409,7 @@ void bookmark_tree::process_link(const string_array &items) void bookmark_tree::process_comment(const astring ¤t_line_in) { -/// FUNCDEF("process_comment"); + FUNCDEF("process_comment"); astring current_line = current_line_in; // output the comment as simple text. diff --git a/nucleus/applications/bookmark_tools/js_marks_maker.cpp b/nucleus/applications/bookmark_tools/js_marks_maker.cpp index d32f50f4..a620e640 100644 --- a/nucleus/applications/bookmark_tools/js_marks_maker.cpp +++ b/nucleus/applications/bookmark_tools/js_marks_maker.cpp @@ -111,7 +111,7 @@ The HOOPLE link format is documented here:\n\ void marks_maker_javascript::write_category(inner_mark_tree *node, astring &output) { -// FUNCDEF("write_category"); + FUNCDEF("write_category"); // output a javascript line for the category. int node_num = node->_uid; @@ -133,7 +133,7 @@ void marks_maker_javascript::write_category(inner_mark_tree *node, astring &outp void marks_maker_javascript::write_link(inner_mark_tree *node, const link_record &linko, astring &output) { -// FUNCDEF("write_link"); + FUNCDEF("write_link"); // write a javascript link definition. int parent_node = node->_uid; astring chewed_name = linko._description; @@ -177,7 +177,7 @@ void marks_maker_javascript::write_link(inner_mark_tree *node, const link_record int marks_maker_javascript::execute() { -// FUNCDEF("execute"); + FUNCDEF("execute"); SETUP_COMBO_LOGGER; command_line cmds(_global_argc, _global_argv); // process the command line parameters. diff --git a/nucleus/applications/bundler/bundle_creator.cpp b/nucleus/applications/bundler/bundle_creator.cpp index a7855255..7bb04947 100644 --- a/nucleus/applications/bundler/bundle_creator.cpp +++ b/nucleus/applications/bundler/bundle_creator.cpp @@ -328,7 +328,7 @@ int bundle_creator::add_files_here(directory &dirndl, const astring &source, int bundle_creator::recurse_into_dir(const astring &source, const astring &target, int manifest_index) { -// FUNCDEF("recurse_into_dir"); + FUNCDEF("recurse_into_dir"); //LOG(astring("src=") + source + " dest=" + target); // we won't include the subversion folder. @@ -366,7 +366,7 @@ int bundle_creator::recurse_into_dir(const astring &source, int bundle_creator::patch_recursive_target(const astring &source, const astring &target, int manifest_index) { -// FUNCDEF("patch_recursive_target"); + FUNCDEF("patch_recursive_target"); //LOG(astring("patch recurs src=") + source + " targ=" + target); return recurse_into_dir(source, target, manifest_index); } @@ -374,7 +374,7 @@ int bundle_creator::patch_recursive_target(const astring &source, int bundle_creator::patch_wildcard_target(const astring &source, const astring &target, int manifest_index) { -// FUNCDEF("patch_wildcard_target"); + FUNCDEF("patch_wildcard_target"); // find the last slash. the rest is our wildcard component. int src_end = source.end(); int slash_indy = source.find('/', src_end, true); @@ -922,7 +922,7 @@ int bundle_creator::finalize_file() int bundle_creator::write_offset() { -// FUNCDEF("write_offset"); + FUNCDEF("write_offset"); byte_filer bun(_output_file, "r+b"); // open the file for updating. astring magic_string("muftiloc"); // our sentinel string. diff --git a/nucleus/applications/bundler/common_bundle.cpp b/nucleus/applications/bundler/common_bundle.cpp index 6d170b59..83ca060e 100644 --- a/nucleus/applications/bundler/common_bundle.cpp +++ b/nucleus/applications/bundler/common_bundle.cpp @@ -59,7 +59,7 @@ bool manifest_chunk::unpack(byte_array &source) bool manifest_chunk::read_an_int(byte_filer &bundle, un_int &found) { -// FUNCDEF("read_an_int"); + FUNCDEF("read_an_int"); byte_array temp; if (bundle.read(temp, sizeof(int)) != sizeof(int)) return false; if (!structures::detach(temp, found)) return false; @@ -68,7 +68,7 @@ bool manifest_chunk::read_an_int(byte_filer &bundle, un_int &found) bool manifest_chunk::read_an_obscured_int(byte_filer &bundle, un_int &found) { -// FUNCDEF("read_an_obscured_int"); + FUNCDEF("read_an_obscured_int"); byte_array temp; if (bundle.read(temp, 2 * sizeof(int)) != 2 * sizeof(int)) return false; if (!structures::obscure_detach(temp, found)) return false; @@ -77,7 +77,7 @@ bool manifest_chunk::read_an_obscured_int(byte_filer &bundle, un_int &found) bool manifest_chunk::read_a_filetime(byte_filer &bundle, byte_array &found) { -// FUNCDEF("read_a_filetime"); + FUNCDEF("read_a_filetime"); byte_array temp; // the trick below only works because we know we have a constant sized packed version // for the file time. @@ -88,7 +88,7 @@ bool manifest_chunk::read_a_filetime(byte_filer &bundle, byte_array &found) astring manifest_chunk::read_a_string(byte_filer &bundle) { -// FUNCDEF("read_a_string"); + FUNCDEF("read_a_string"); astring found; byte_array temp; // read in the zero-terminated character string. diff --git a/nucleus/library/application/command_line.cpp b/nucleus/library/application/command_line.cpp index 19f61810..0fb818aa 100644 --- a/nucleus/library/application/command_line.cpp +++ b/nucleus/library/application/command_line.cpp @@ -236,7 +236,7 @@ bool command_line::zap(int field) string_array command_line::get_command_line() { -// FUNCDEF("get_command_line"); + FUNCDEF("get_command_line"); string_array listo_cmds; // the temporary string below can be given a flat formatting of the commands // and it will be popped out into a list of arguments. diff --git a/nucleus/library/application/launch_manager.cpp b/nucleus/library/application/launch_manager.cpp index 7e07c1e6..2bc32d2a 100644 --- a/nucleus/library/application/launch_manager.cpp +++ b/nucleus/library/application/launch_manager.cpp @@ -137,7 +137,7 @@ launch_manager::launch_manager(configured_applications &config) _gag_exclusions(new string_set), _tracking_exclusions(new string_set) { -// FUNCDEF("constructor"); + FUNCDEF("constructor"); // start the application checking thread. _checker->start(NIL); @@ -578,7 +578,7 @@ bool launch_manager::get_processes(process_entry_array &processes) bool launch_manager::find_process(const astring &app_name_in, int_set &pids) { -// FUNCDEF("find_process"); + FUNCDEF("find_process"); pids.clear(); process_entry_array processes; if (!get_processes(processes)) return false; diff --git a/nucleus/library/application/redirecter.cpp b/nucleus/library/application/redirecter.cpp index 78091446..c0b7e864 100644 --- a/nucleus/library/application/redirecter.cpp +++ b/nucleus/library/application/redirecter.cpp @@ -218,7 +218,7 @@ outcome stdio_redirecter::create_pipes() outcome stdio_redirecter::launch_program(int &new_process_id) { -// FUNCDEF("launch_program"); + FUNCDEF("launch_program"); new_process_id = 0; #ifdef __UNIX__ int fork_ret = fork(); @@ -438,7 +438,7 @@ outcome stdio_redirecter::write(const astring &to_write, int &written) outcome stdio_redirecter::write(const byte_array &to_write, int &written) { -// FUNCDEF("write"); + FUNCDEF("write"); written = 0; if (_persistent_result != OKAY) return _persistent_result; #ifdef __UNIX__ @@ -470,7 +470,7 @@ outcome stdio_redirecter::read_stderr(byte_array &received) void stdio_redirecter::std_thread_action(bool is_stdout) { -// FUNCDEF("std_thread_action"); + FUNCDEF("std_thread_action"); byte_array buff(BUFFER_SIZE + 1); #ifdef __UNIX__ bool ret = false; diff --git a/nucleus/library/application/shared_memory.cpp b/nucleus/library/application/shared_memory.cpp index 4dab6191..c26a09c5 100644 --- a/nucleus/library/application/shared_memory.cpp +++ b/nucleus/library/application/shared_memory.cpp @@ -53,7 +53,7 @@ shared_memory::shared_memory(int size, const char *identity) _identity(new astring(identity)), _size(size) { -// FUNCDEF("constructor"); + FUNCDEF("constructor"); bool first_use = false; // assume already existing until told otherwise. _locking->lock(); // force all others to wait on our finishing creation. #ifdef __UNIX__ diff --git a/nucleus/library/configuration/application_configuration.cpp b/nucleus/library/configuration/application_configuration.cpp index a3a0636a..5e7feac0 100644 --- a/nucleus/library/configuration/application_configuration.cpp +++ b/nucleus/library/configuration/application_configuration.cpp @@ -137,7 +137,7 @@ astring application_configuration::get_cmdline_from_proc() // deprecated; better to use the /proc/pid/cmdline file. astring application_configuration::query_for_process_info() { -// FUNCDEF("query_for_process_info"); + FUNCDEF("query_for_process_info"); astring to_return = "unknown"; // we ask the operating system about our process identifier and store // the results in a temporary file. @@ -198,7 +198,7 @@ astring application_configuration::query_for_process_info() astring application_configuration::application_name() { -// FUNCDEF("application_name"); + FUNCDEF("application_name"); astring to_return; #ifdef __APPLE__ char buffer[MAX_ABS_PATH] = { '\0' }; diff --git a/nucleus/library/configuration/ini_configurator.cpp b/nucleus/library/configuration/ini_configurator.cpp index c65bdcca..8f66f01a 100644 --- a/nucleus/library/configuration/ini_configurator.cpp +++ b/nucleus/library/configuration/ini_configurator.cpp @@ -227,7 +227,7 @@ bool ini_configurator::delete_entry(const astring §ion, const astring &ent) bool ini_configurator::put(const astring §ion, const astring &entry, const astring &to_store) { -/// FUNCDEF("put"); + FUNCDEF("put"); if (!to_store.length()) return delete_entry(section, entry); else if (!entry.length()) return delete_section(section); else if (!section.length()) return false; @@ -259,7 +259,7 @@ bool ini_configurator::get(const astring §ion, const astring &entry, bool ini_configurator::get_section(const astring §ion, string_table &info) { -/// FUNCDEF("get_section"); + FUNCDEF("get_section"); #ifndef __WIN32__ return _parser->get_section(section, info); #else diff --git a/nucleus/library/configuration/system_values.cpp b/nucleus/library/configuration/system_values.cpp index c82b515e..c9b74f19 100644 --- a/nucleus/library/configuration/system_values.cpp +++ b/nucleus/library/configuration/system_values.cpp @@ -84,7 +84,7 @@ system_values::system_values(const astring §ion_tag) _list(new system_values_lookup_list), _file(new astring(DEFAULT_MANIFEST)) { -// FUNCDEF("constructor"); + FUNCDEF("constructor"); open_values(); } @@ -113,7 +113,7 @@ const char *system_values::EVENT_VALUES() { return "DEFINE_EVENT"; } bool system_values::open_values() { -// FUNCDEF("open_values"); + FUNCDEF("open_values"); ini_configurator ini(*_file, ini_configurator::RETURN_ONLY, ini_configurator::APPLICATION_DIRECTORY); diff --git a/nucleus/library/configuration/table_configurator.cpp b/nucleus/library/configuration/table_configurator.cpp index 692ed0d0..b4426df2 100644 --- a/nucleus/library/configuration/table_configurator.cpp +++ b/nucleus/library/configuration/table_configurator.cpp @@ -170,7 +170,7 @@ astring table_configurator::clean_comments(const astring &to_clean, bool table_configurator::get_section(const astring §ion, string_table &info) { -/// FUNCDEF("get_section"); + FUNCDEF("get_section"); info.reset(); string_table *sect = _real_table->find(section); if (!sect) return false; @@ -182,7 +182,7 @@ bool table_configurator::get_section(const astring §ion, bool table_configurator::put_section(const astring §ion, const string_table &info) { -/// FUNCDEF("put_section"); + FUNCDEF("put_section"); string_table *sect = _real_table->find(section); if (!sect) { // none exists yet, so add one. diff --git a/nucleus/library/filesystem/directory_tree.cpp b/nucleus/library/filesystem/directory_tree.cpp index b6742e93..68b82b7f 100644 --- a/nucleus/library/filesystem/directory_tree.cpp +++ b/nucleus/library/filesystem/directory_tree.cpp @@ -34,7 +34,7 @@ using namespace nodes; using namespace structures; using namespace textual; -//#define DEBUG_DIRECTORY_TREE +#define DEBUG_DIRECTORY_TREE // uncomment for noisier version. #undef LOG @@ -224,12 +224,18 @@ void directory_tree::traverse(const astring &path, const char *pattern, bool directory_tree::reset(const astring &path, const char *pattern) { + FUNCDEF("reset"); _scanned_okay = false; WHACK(_real_tree); +// filename temp_path(path); +// temp_path.canonicalize(); *_path = path; +//temp_path.raw(); *_pattern = pattern; _real_tree = new filename_tree; +LOG(astring("dirtree::reset to path: ") + path); + // check that the top-level is healthy. directory curr(path, "*"); if (!curr.good()) return false; @@ -617,6 +623,11 @@ bool directory_tree::compare_trees(const directory_tree &source, if (target_start.raw().t()) { corresponding_name = filename(target_start.raw() + filename::default_separator() + corresponding_name.raw()); +/*doesn't help, not right yet. } else { + // if they didn't give us a place to start, we start at the top. + corresponding_name = filename(target.path() + + filename::default_separator() + corresponding_name.raw()); +*/ } #ifdef DEBUG_DIRECTORY_TREE LOG(astring("target with start is: ") + corresponding_name); diff --git a/nucleus/library/filesystem/filename.cpp b/nucleus/library/filesystem/filename.cpp index 2a97d3a4..adca7e99 100644 --- a/nucleus/library/filesystem/filename.cpp +++ b/nucleus/library/filesystem/filename.cpp @@ -434,7 +434,7 @@ void filename::separate(string_array &pieces) const if (separator(raw_form[i])) { // this is a separator character, so eat it and add the accumulated // string to the list. - if (!i || accumulator.length()) pieces += accumulator; + if (i && accumulator.length()) pieces += accumulator; // now reset our accumulated text. accumulator = astring::empty_string(); } else { diff --git a/nucleus/library/filesystem/filename.h b/nucleus/library/filesystem/filename.h index 8e257358..9c4eb56b 100644 --- a/nucleus/library/filesystem/filename.h +++ b/nucleus/library/filesystem/filename.h @@ -186,10 +186,12 @@ public: character that is substituted instead of illegal characters. */ void separate(structures::string_array &pieces) const; - //!< breaks the filename into its component directories. + //!< breaks the filename into its component parts. /*!< this returns an array containing the component names. the last component, unless the filename held is actually a directory, should be the - name of the file. if the first character is a directory, then the first + name of the file. +//hmmm: what does this mean, below? + if the first character is a directory, then the first component will be empty. */ void join(const structures::string_array &pieces); diff --git a/nucleus/library/filesystem/heavy_file_ops.cpp b/nucleus/library/filesystem/heavy_file_ops.cpp index 3ddd7664..6c4765e9 100644 --- a/nucleus/library/filesystem/heavy_file_ops.cpp +++ b/nucleus/library/filesystem/heavy_file_ops.cpp @@ -40,6 +40,11 @@ namespace filesystem { ////////////// +// the smallest we let the packing area's available space get before we stop filling it. +const int MINIMUM_ARRAY_SIZE = 1024; + +////////////// + file_transfer_header::file_transfer_header(const file_time &time_stamp) : _filename(), _byte_start(0), @@ -167,9 +172,7 @@ outcome heavy_file_operations::write_file_chunk(const astring &target, double byte_start, const byte_array &chunk, bool truncate, int copy_chunk_factor) { -#ifdef DEBUG_HEAVY_FILE_OPS -// FUNCDEF("write_file_chunk"); -#endif + FUNCDEF("write_file_chunk"); if (byte_start < 0) return BAD_INPUT; filename targ_name(target); @@ -247,7 +250,7 @@ outcome heavy_file_operations::buffer_files(const astring &source_root, while (storage.length() < maximum_bytes) { double remaining_in_array = maximum_bytes - storage.length() - last_action.packed_size(); - if (remaining_in_array < 128) { + if (remaining_in_array < MINIMUM_ARRAY_SIZE) { // ensure that we at least have a reasonable amount of space left // for storing into the array. break; @@ -273,15 +276,15 @@ outcome heavy_file_operations::buffer_files(const astring &source_root, huge_file current(full_file, "rb"); if (!current.good()) { // we need to skip this file. -LOG(astring("skipping bad file: ") + full_file); + LOG(astring("skipping bad file: ") + full_file); to_return = advance(to_transfer, last_action); if (to_return != OKAY) break; continue; } if (last_action._byte_start + last_action._length >= current.length()) { -LOG(astring("finished stuffing file: ") + full_file); // this file is done now. go to the next one. + LOG(astring("finished stuffing file: ") + full_file); to_return = advance(to_transfer, last_action); if (to_return != OKAY) break; continue; diff --git a/nucleus/library/filesystem/heavy_file_ops.h b/nucleus/library/filesystem/heavy_file_ops.h index 028bb8e2..debb5773 100644 --- a/nucleus/library/filesystem/heavy_file_ops.h +++ b/nucleus/library/filesystem/heavy_file_ops.h @@ -30,6 +30,7 @@ class file_transfer_header : public basis::packable { public: basis::astring _filename; //!< the name of the file being transferred. +//hmmm: consider adding full length here so we know it. double _byte_start; //!< the starting location in the file being sent. int _length; //!< the length of the transferred piece. file_time _time; //!< the timestamp on the file. diff --git a/nucleus/library/filesystem/huge_file.cpp b/nucleus/library/filesystem/huge_file.cpp index 4c218c56..acf9adc7 100644 --- a/nucleus/library/filesystem/huge_file.cpp +++ b/nucleus/library/filesystem/huge_file.cpp @@ -254,7 +254,7 @@ outcome huge_file::seek(double new_position, byte_filer::origins origin) outcome huge_file::read(byte_array &to_fill, int desired_size, int &size_read) { -// FUNCDEF("read"); + FUNCDEF("read"); size_read = 0; int ret = _real_file->read(to_fill, desired_size); if (ret < 0) @@ -266,7 +266,7 @@ outcome huge_file::read(byte_array &to_fill, int desired_size, int &size_read) outcome huge_file::write(const byte_array &to_write, int &size_written) { -// FUNCDEF("write"); + FUNCDEF("write"); size_written = 0; int ret = _real_file->write(to_write); if (ret < 0) diff --git a/nucleus/library/nodes/packable_tree.cpp b/nucleus/library/nodes/packable_tree.cpp index a38f88ad..2d8a9925 100644 --- a/nucleus/library/nodes/packable_tree.cpp +++ b/nucleus/library/nodes/packable_tree.cpp @@ -23,7 +23,7 @@ using namespace basis; using namespace structures; -//#define DEBUG_PACKABLE_TREE +#define DEBUG_PACKABLE_TREE // uncomment for noisy debugging. #undef LOG @@ -92,8 +92,8 @@ LOG(a_sprintf("len A %d", size_accumulator)); void packable_tree::packit(byte_array &packed_form, const packable_tree *current_node) { -LOG(a_sprintf("packing node %x", current_node)); -LOG(a_sprintf("size A %d", packed_form.length())); +//LOG(a_sprintf("packing node %x", current_node)); +//LOG(a_sprintf("size A %d", packed_form.length())); FUNCDEF("packit"); if (!current_node) throw_error(static_class_name(), func, "current node is nil"); @@ -119,9 +119,9 @@ throw_error(current_node->class_name(), func, "failure calculating size"); } // stuff the command unit. command.pack(packed_form); -LOG(a_sprintf("size B %d", packed_form.length())); +//LOG(a_sprintf("size B %d", packed_form.length())); packed_form += temp_store; // main chunk is not packed, just added. -LOG(a_sprintf("size C %d", packed_form.length())); +//LOG(a_sprintf("size C %d", packed_form.length())); } int packable_tree::recursive_packed_size() const diff --git a/nucleus/library/processes/configured_applications.cpp b/nucleus/library/processes/configured_applications.cpp index 1c8e4617..87add502 100644 --- a/nucleus/library/processes/configured_applications.cpp +++ b/nucleus/library/processes/configured_applications.cpp @@ -68,7 +68,7 @@ configured_applications::configured_applications(const astring &config_file, _sector(new section_manager(*_config, astring(basename) + "_TOC", astring(PRODUCT_HEADING()) + "_")) { -// FUNCDEF("constructor"); + FUNCDEF("constructor"); string_table startup_info; if (!find_section(STARTUP_SECTION(), startup_info)) { // if there's no startup section, we do nothing right now. @@ -179,7 +179,7 @@ bool configured_applications::add_program(const astring &product, bool configured_applications::remove_program(const astring &product, const astring &app_name) { -// FUNCDEF("remove_program"); + FUNCDEF("remove_program"); auto_synchronizer l(*_lock); // if the section's missing, there's nothing to remove... string_table info_table; @@ -194,7 +194,7 @@ bool configured_applications::remove_program(const astring &product, bool configured_applications::find_section(const astring §ion_name, string_table &info_found) { -// FUNCDEF("find_section"); + FUNCDEF("find_section"); info_found.reset(); auto_synchronizer l(*_lock); if (!_sector->find_section(section_name, info_found)) { @@ -230,7 +230,7 @@ astring configured_applications::make_startup_entry(const astring &product, bool configured_applications::parse_startup_entry(const astring &info, astring &product, astring &parms, bool &one_shot) { -// FUNCDEF("parse_startup_section"); + FUNCDEF("parse_startup_section"); // parse the items that are in the entry for this program. variable_tokenizer entry_parser(SEPARATOR_TOKEN(), ASSIGN_TOKEN()); entry_parser.parse(info); @@ -259,7 +259,7 @@ bool configured_applications::find_entry(const string_table &table, bool configured_applications::add_startup_entry(const astring &product, const astring &app_name, const astring ¶meters, int one_shot) { -// FUNCDEF("add_startup_entry"); + FUNCDEF("add_startup_entry"); auto_synchronizer l(*_lock); LOG(astring("product \"") + product + "\", application \"" + app_name @@ -286,7 +286,7 @@ bool configured_applications::add_startup_entry(const astring &product, bool configured_applications::remove_startup_entry(const astring &product, const astring &app_name) { -// FUNCDEF("remove_startup_entry"); + FUNCDEF("remove_startup_entry"); auto_synchronizer l(*_lock); LOG(astring("product \"") + product + "\", application \"" + app_name + "\""); diff --git a/nucleus/library/processes/ethread.cpp b/nucleus/library/processes/ethread.cpp index 30efcc88..84e15498 100644 --- a/nucleus/library/processes/ethread.cpp +++ b/nucleus/library/processes/ethread.cpp @@ -99,7 +99,7 @@ ethread::ethread() _next_activation(new time_stamp), _how(TIGHT_INTERVAL) // unused. { -// FUNCDEF("constructor [one-shot]"); + FUNCDEF("constructor [one-shot]"); } ethread::ethread(int sleep_timer, timed_thread_types how) @@ -117,7 +117,7 @@ ethread::ethread(int sleep_timer, timed_thread_types how) _next_activation(new time_stamp), _how(how) { -// FUNCDEF("constructor [periodic]"); + FUNCDEF("constructor [periodic]"); if (sleep_timer < MINIMUM_SLEEP_PERIOD) { _sleep_time = MINIMUM_SLEEP_PERIOD; } @@ -226,7 +226,7 @@ void ethread::one_shot_thread_driver(void *hidden_pointer) #error unknown thread signature. #endif { -// FUNCDEF("one_shot_thread_driver"); + FUNCDEF("one_shot_thread_driver"); ethread *manager = (ethread *)hidden_pointer; #ifdef __UNIX__ if (!manager) return NIL; @@ -260,7 +260,7 @@ void ethread::periodic_thread_driver(void *hidden_pointer) #error unknown thread signature. #endif { -// FUNCDEF("periodic_thread_driver"); + FUNCDEF("periodic_thread_driver"); ethread *manager = (ethread *)hidden_pointer; #ifdef __UNIX__ if (!manager) return NIL; diff --git a/nucleus/library/processes/process_control.cpp b/nucleus/library/processes/process_control.cpp index 96485c8c..c4025bda 100644 --- a/nucleus/library/processes/process_control.cpp +++ b/nucleus/library/processes/process_control.cpp @@ -297,7 +297,7 @@ bool process_control::zap_process(basis::un_int to_zap) process_entry process_control::query_process(basis::un_int to_query) { -// FUNCDEF("query_process"); + FUNCDEF("query_process"); process_entry to_return; process_entry_array to_fill; diff --git a/nucleus/library/structures/memory_limiter.cpp b/nucleus/library/structures/memory_limiter.cpp index b0756a8a..134c813c 100644 --- a/nucleus/library/structures/memory_limiter.cpp +++ b/nucleus/library/structures/memory_limiter.cpp @@ -126,7 +126,7 @@ astring memory_limiter::text_form(int indent) const bool memory_limiter::okay_allocation(int individual, int memory_desired) { -// FUNCDEF("okay_allocation"); + FUNCDEF("okay_allocation"); // check the overall allocation limits first. if (_overall_limit && (_overall_size + memory_desired > _overall_limit) ) return false; diff --git a/nucleus/library/tests_basis/test_string.cpp b/nucleus/library/tests_basis/test_string.cpp index f89318a9..a4263ba4 100644 --- a/nucleus/library/tests_basis/test_string.cpp +++ b/nucleus/library/tests_basis/test_string.cpp @@ -512,7 +512,7 @@ void test_string::run_test_12() void test_string::run_test_13() { -// FUNCDEF("run_test_13"); + FUNCDEF("run_test_13"); // check for possible memory leaks in these combined ops.... 13th. const astring churg("borjh sjh oiweoklj"); astring pud = churg; @@ -603,7 +603,7 @@ void test_string::run_test_16() void test_string::run_test_17() { -// FUNCDEF("run_test_17"); + FUNCDEF("run_test_17"); // 17th test checks construction of temporaries. /* this test set causes the obnoxious 16 bit codeguard error from hell, as does use of temporary objects in ostream << operators. argh! */ @@ -810,7 +810,7 @@ void test_string::run_test_25() void test_string::run_test_26() { -// FUNCDEF("run_test_26"); + FUNCDEF("run_test_26"); // 26th test group does simple time_stamp::notarize operations. these are more for // ensuring boundschecker gets to see some of this. astring t2 = time_stamp::notarize(false); @@ -819,7 +819,7 @@ void test_string::run_test_26() void test_string::run_test_27() { -// FUNCDEF("run_test_27"); + FUNCDEF("run_test_27"); // 27th test group plays around with idate in an attempt to get // boundschecker to complain. timely::day_in_year d1 = date_now(); @@ -859,7 +859,7 @@ void test_string::run_test_29() void standard_sprintf_test(const char *parm_string) { -// FUNCDEF("standard_sprintf_test"); + FUNCDEF("standard_sprintf_test"); astring print_into(' ', 20000); print_into[0] = '\0'; //check these!!!: @@ -993,7 +993,7 @@ void test_string::run_test_33() void test_string::run_test_34() { -// FUNCDEF("run_test_34"); + FUNCDEF("run_test_34"); //not in use right now. @@ -1070,7 +1070,7 @@ void test_string::run_test_37() void test_string::run_test_38() { -// FUNCDEF("run_test_38"); + FUNCDEF("run_test_38"); double to_print = 2.345; a_sprintf non_deadly("%.1f", to_print); /// LOG(astring("printed: ") + non_deadly); diff --git a/nucleus/library/tests_filesystem/test_byte_filer.cpp b/nucleus/library/tests_filesystem/test_byte_filer.cpp index b37faaba..283ebb05 100644 --- a/nucleus/library/tests_filesystem/test_byte_filer.cpp +++ b/nucleus/library/tests_filesystem/test_byte_filer.cpp @@ -226,7 +226,7 @@ int test_byte_filer::run_file_scan() int test_byte_filer::execute() { -// FUNCDEF("execute"); + FUNCDEF("execute"); int ret = run_simple_test(); if (ret) return ret; // failed. ret = run_file_scan(); diff --git a/nucleus/library/tests_filesystem/test_directory_tree.cpp b/nucleus/library/tests_filesystem/test_directory_tree.cpp index c1894aca..756138ca 100644 --- a/nucleus/library/tests_filesystem/test_directory_tree.cpp +++ b/nucleus/library/tests_filesystem/test_directory_tree.cpp @@ -122,10 +122,10 @@ int test_directory_tree::execute() directory_tree dir2(path, pattern.s()); ASSERT_TRUE(dir2.good(), "the directory should read the second time fine too"); -// LOG("comparing the two trees."); + LOG("comparing the two trees."); filename_list diffs; directory_tree::compare_trees(dir, dir2, diffs, file_info::EQUAL_CHECKSUM_TIMESTAMP_FILESIZE); -//LOG(diffs.text_form()); +LOG(diffs.text_form()); ASSERT_FALSE(diffs.elements(), "there should be no differences comparing identical dirs"); } diff --git a/nucleus/library/tests_filesystem/test_filename.cpp b/nucleus/library/tests_filesystem/test_filename.cpp index 53276b37..e2377777 100644 --- a/nucleus/library/tests_filesystem/test_filename.cpp +++ b/nucleus/library/tests_filesystem/test_filename.cpp @@ -60,11 +60,11 @@ int test_filename::execute() filename turkey("/omega/ralph/turkey/buzzard.txt"); string_array pieces; turkey.separate(pieces); - ASSERT_TRUE(pieces[1].equal_to("omega"), GROUP + "the first piece didn't match."); - ASSERT_TRUE(pieces[2].equal_to("ralph"), GROUP + "the second piece didn't match."); - ASSERT_TRUE(pieces[3].equal_to("turkey"), GROUP + "the third piece didn't match."); - ASSERT_TRUE(pieces[4].equal_to("buzzard.txt"), GROUP + "the fourth piece didn't match."); - ASSERT_EQUAL(pieces.length(), 5, GROUP + "the list was the wrong length"); + ASSERT_TRUE(pieces[0].equal_to("omega"), GROUP + "the first piece didn't match."); + ASSERT_TRUE(pieces[1].equal_to("ralph"), GROUP + "the second piece didn't match."); + ASSERT_TRUE(pieces[2].equal_to("turkey"), GROUP + "the third piece didn't match."); + ASSERT_TRUE(pieces[3].equal_to("buzzard.txt"), GROUP + "the fourth piece didn't match."); + ASSERT_EQUAL(pieces.length(), 4, GROUP + "the list was the wrong length"); } { diff --git a/nucleus/library/versions/version_ini.cpp b/nucleus/library/versions/version_ini.cpp index 7edb6f1e..40d0d3c3 100644 --- a/nucleus/library/versions/version_ini.cpp +++ b/nucleus/library/versions/version_ini.cpp @@ -168,7 +168,7 @@ version_record &version_ini::access_record() { return *_held_record; } version_record version_ini::get_record() { -// FUNCDEF("get_record"); + FUNCDEF("get_record"); if (_loaded) return *_held_record; version_record to_return; to_return.description = _ini->load(VERSION_SECTION, DESCRIPTION, ""); @@ -450,7 +450,7 @@ bool replace_version_entry(astring &full_string, const astring &look_for, bool version_ini::write_assembly(const version_record &to_write, bool do_logging) { -// FUNCDEF("write_assembly"); + FUNCDEF("write_assembly"); filename just_dir = _path_name->dirname(); //LOG(astring("dir is set to: ") + just_dir); directory dir(just_dir); diff --git a/nucleus/tools/clam_tools/version_stamper.cpp b/nucleus/tools/clam_tools/version_stamper.cpp index a668a9f0..b66a34d0 100644 --- a/nucleus/tools/clam_tools/version_stamper.cpp +++ b/nucleus/tools/clam_tools/version_stamper.cpp @@ -65,7 +65,7 @@ version_stamper::~version_stamper() {} int version_stamper::execute() { -/// FUNCDEF("execute"); + FUNCDEF("execute"); SETUP_CONSOLE_LOGGER; // override the file_logger from app_shell. if (application::_global_argc < 2) { log(astring("The directory where the 'version.ini' file is located\n" diff --git a/nucleus/tools/clam_tools/vsts_version_fixer.cpp b/nucleus/tools/clam_tools/vsts_version_fixer.cpp index f43ce64f..9226adfa 100644 --- a/nucleus/tools/clam_tools/vsts_version_fixer.cpp +++ b/nucleus/tools/clam_tools/vsts_version_fixer.cpp @@ -96,7 +96,7 @@ HOOPLE_MAIN(vsts_version_fixer, ) bool vsts_version_fixer::spider_directory(directory start, spider_method to_invoke) { -// FUNCDEF("spider_directory"); + FUNCDEF("spider_directory"); using namespace basis; @@ -133,7 +133,7 @@ string_array global_dir_whacks; bool whacking_spider(const directory ¤t) { -// FUNCDEF("whacking_spider"); + FUNCDEF("whacking_spider"); using namespace basis; //LOG(astring("whacking_spider: ") + current.path()); // iterate across the files in the directory and check for evil ones. @@ -205,7 +205,7 @@ basis::astring global_build_ini; bool stamping_spider(const directory ¤t) { -// FUNCDEF("stamping_spider"); + FUNCDEF("stamping_spider"); using namespace basis; //LOG(astring("stamping_spider: ") + current.path()); @@ -232,7 +232,7 @@ bool stamping_spider(const directory ¤t) bool vsts_version_fixer::perform_version_stamping(const filename &start_name) { -// FUNCDEF("perform_version_stamping"); + FUNCDEF("perform_version_stamping"); directory start(start_name); return spider_directory(start, stamping_spider); } diff --git a/nucleus/tools/clam_tools/write_build_config.cpp b/nucleus/tools/clam_tools/write_build_config.cpp index 6f463284..6a9a30b5 100644 --- a/nucleus/tools/clam_tools/write_build_config.cpp +++ b/nucleus/tools/clam_tools/write_build_config.cpp @@ -166,7 +166,7 @@ outcome write_build_config::output_decorated_macro(const astring &symbol_in, outcome write_build_config::output_definition_macro (const astring &embedded_value, astring &accumulator) { -// FUNCDEF("output_definition_macro"); + FUNCDEF("output_definition_macro"); //LOG(astring("into output def with: ") + embedded_value); variable_tokenizer t; t.parse(embedded_value); diff --git a/nucleus/tools/simple_utilities/create_guid.cpp b/nucleus/tools/simple_utilities/create_guid.cpp index 104bde72..e23dfe71 100644 --- a/nucleus/tools/simple_utilities/create_guid.cpp +++ b/nucleus/tools/simple_utilities/create_guid.cpp @@ -57,7 +57,7 @@ public: int create_guid::execute() { -// FUNCDEF("execute"); + FUNCDEF("execute"); SETUP_CONSOLE_LOGGER; #ifdef __UNIX__ diff --git a/octopi/applications/transporter/synch_files.cpp b/octopi/applications/transporter/synch_files.cpp index 506ad4c4..2c424663 100644 --- a/octopi/applications/transporter/synch_files.cpp +++ b/octopi/applications/transporter/synch_files.cpp @@ -42,7 +42,7 @@ public: int synch_files_tentacle::execute() { -// FUNCDEF("execute"); + FUNCDEF("execute"); if (_global_argc < 3) { log(astring("\ diff --git a/octopi/library/cromp/cromp_client.cpp b/octopi/library/cromp/cromp_client.cpp index 8baae692..ef7f8931 100644 --- a/octopi/library/cromp/cromp_client.cpp +++ b/octopi/library/cromp/cromp_client.cpp @@ -154,7 +154,7 @@ cromp_client::cromp_client(const internet_address &addr, int connection_wait, cromp_client::~cromp_client() { -// FUNCDEF("destructor"); + FUNCDEF("destructor"); disconnect(); close_common(); _identified = false; @@ -175,7 +175,7 @@ const byte_array &cromp_client::verification() const void cromp_client::enable_encryption() { -// FUNCDEF("enable_encryption"); + FUNCDEF("enable_encryption"); AUTO_LOCK; #ifdef DEBUG_CROMP_CLIENT @@ -398,7 +398,7 @@ outcome cromp_client::login() outcome cromp_client::connect(const byte_array &verification) { -// FUNCDEF("connect"); + FUNCDEF("connect"); stop_asynch_thread(); AUTO_LOCK; // protect from multiple connect attempts. *c_verification = verification; diff --git a/octopi/library/cromp/cromp_common.cpp b/octopi/library/cromp/cromp_common.cpp index 107d92ae..0aeb2e69 100644 --- a/octopi/library/cromp/cromp_common.cpp +++ b/octopi/library/cromp/cromp_common.cpp @@ -140,7 +140,7 @@ cromp_common::cromp_common(const astring &host, int max_per_ent) _still_flat(new byte_array(CROMP_BUFFER_CHUNK_SIZE, NIL)), _last_cleanup(new time_stamp) { -// FUNCDEF("constructor [host/max_per_ent]"); + FUNCDEF("constructor [host/max_per_ent]"); // clear pre-existing space. _accumulator->reset(); _sendings->reset(); @@ -179,7 +179,7 @@ cromp_common::cromp_common(spocket *preexisting, octopus *singleton) cromp_common::~cromp_common() { -// FUNCDEF("destructor"); + FUNCDEF("destructor"); close_common(); // shuts down our socket and other stuff. if (_singleton) { _singleton = NIL; // reset the pointer we had. @@ -277,7 +277,7 @@ void cromp_common::max_bytes_per_entity(int max_bytes_per_entity) void cromp_common::conditional_cleaning() { -// FUNCDEF("conditional_cleaning"); + FUNCDEF("conditional_cleaning"); if (time_stamp(-CLEANUP_INTERVAL) > *_last_cleanup) { _requests->clean_out_deadwood(); // flush any items that are too old. @@ -500,7 +500,7 @@ outcome cromp_common::send_buffer() outcome cromp_common::retrieve_and_restore_root(bool get_anything, infoton * &item, octopus_request_id &req_id, int timeout) { -// FUNCDEF("retrieve_and_restore_root"); + FUNCDEF("retrieve_and_restore_root"); item = NIL; if (!_commlink) return BAD_INPUT; // they haven't opened this yet. octopus_request_id tmp_id; diff --git a/octopi/library/cromp/cromp_server.cpp b/octopi/library/cromp/cromp_server.cpp index 2fc7089f..73bda545 100644 --- a/octopi/library/cromp/cromp_server.cpp +++ b/octopi/library/cromp/cromp_server.cpp @@ -182,7 +182,7 @@ public: // stops the background activity of this object and drops the connection // to the client. void croak() { -// FUNCDEF("croak"); + FUNCDEF("croak"); _grabber.stop(); int actions = 0; while (get_incoming_data(actions)) { @@ -450,7 +450,7 @@ public: _parent(parent) {} void perform_activity(void *formal(ptr)) { -// FUNCDEF("perform_activity"); + FUNCDEF("perform_activity"); _parent.drop_dead_clients(); } @@ -468,7 +468,7 @@ public: _parent(parent) {} void perform_activity(void *formal(ptr)) { -// FUNCDEF("perform_activity"); + FUNCDEF("perform_activity"); _parent.look_for_clients(*this); } @@ -498,7 +498,7 @@ cromp_server::cromp_server(const internet_address &where, _default_security(new cromp_security), _security_arm(NIL) { -// FUNCDEF("constructor"); + FUNCDEF("constructor"); } cromp_server::~cromp_server() @@ -613,7 +613,7 @@ outcome cromp_server::enable_servers(bool encrypt, cromp_security *security) void cromp_server::disable_servers() { -// FUNCDEF("disable_servers"); + FUNCDEF("disable_servers"); if (!_enabled) return; _dropper->stop(); // signal the thread to leave when it can. _accepters->stop_all(); // signal the accepting threads to exit. @@ -648,7 +648,7 @@ int cromp_server::clients() const bool cromp_server::disconnect_entity(const octopus_entity &id) { -// FUNCDEF("disconnect_entity"); + FUNCDEF("disconnect_entity"); if (!_enabled) return false; LOCK_LISTS; int indy = _clients->find(id); @@ -662,7 +662,7 @@ bool cromp_server::disconnect_entity(const octopus_entity &id) bool cromp_server::find_entity(const octopus_entity &id, internet_address &found) { -// FUNCDEF("find_entity"); + FUNCDEF("find_entity"); if (!_enabled) return false; found = internet_address(); LOCK_LISTS; @@ -761,7 +761,7 @@ outcome cromp_server::send_to_client(const octopus_request_id &id, outcome cromp_server::get_from_client(const octopus_request_id &id, infoton * &data, int timeout) { -// FUNCDEF("get_from_client"); + FUNCDEF("get_from_client"); if (!_enabled) return common::INCOMPLETE; //hmmm: this implementation locks the lists; can't we get the client to do // most of the work for this? diff --git a/octopi/library/octopus/entity_data_bin.cpp b/octopi/library/octopus/entity_data_bin.cpp index 080e758c..427deb16 100644 --- a/octopi/library/octopus/entity_data_bin.cpp +++ b/octopi/library/octopus/entity_data_bin.cpp @@ -189,7 +189,7 @@ bool scramble_applier(const octopus_entity &formal(key), entity_basket &bask, { #undef static_class_name #define static_class_name() "entity_data_bin" -// FUNCDEF("scramble_applier"); + FUNCDEF("scramble_applier"); int *county = (int *)data_link; *county += bask.elements(); return true; @@ -219,7 +219,7 @@ int entity_data_bin::scramble_counter() bool entity_data_bin::add_item(infoton *to_add, const octopus_request_id &orig_id) { -// FUNCDEF("add_item"); + FUNCDEF("add_item"); GRAB_LOCK; // create a record to add to the appropriate bin. infoton_holder *holder = new infoton_holder(orig_id, to_add); @@ -253,10 +253,8 @@ bool entity_data_bin::add_item(infoton *to_add, bool any_item_applier(const octopus_entity &formal(key), entity_basket &bask, void *data_link) { -//#ifdef DEBUG_ENTITY_DATA_BIN -// #define static_class_name() "entity_data_bin" -// FUNCDEF("any_item_applier"); -//#endif + #define static_class_name() "entity_data_bin" + FUNCDEF("any_item_applier"); apply_struct *apple = (apply_struct *)data_link; // check the basket to see if it has any items. if (!bask.elements()) { @@ -304,7 +302,7 @@ infoton *entity_data_bin::acquire_for_any(octopus_request_id &id) int entity_data_bin::acquire_for_entity(const octopus_entity &requester, infoton_list &items, int maximum_size) { -// FUNCDEF("acquire_for_entity [multiple]"); + FUNCDEF("acquire_for_entity [multiple]"); // this method does not grab the lock because it simply composes other // class methods without interacting with class data members. items.reset(); @@ -473,7 +471,7 @@ void entity_data_bin::clean_out_deadwood(int decay_interval) bool entity_data_bin::get_sizes(const octopus_entity &id, int &items, int &bytes) { -// FUNCDEF("get_sizes"); + FUNCDEF("get_sizes"); items = 0; bytes = 0; GRAB_LOCK; diff --git a/octopi/library/octopus/infoton.cpp b/octopi/library/octopus/infoton.cpp index 15f817d1..49468408 100644 --- a/octopi/library/octopus/infoton.cpp +++ b/octopi/library/octopus/infoton.cpp @@ -41,20 +41,20 @@ const abyte FAST_PACK_VERSION = 0x14; infoton::infoton(const string_array &classifier) : _classifier(new string_array(classifier)) { -// FUNCDEF("constructor [string_array]"); + FUNCDEF("constructor [string_array]"); } infoton::infoton(const astring &class_1) : _classifier(new string_array) { -// FUNCDEF("constructor [one string]"); + FUNCDEF("constructor [one string]"); *_classifier += class_1; } infoton::infoton(const astring &class_1, const astring &class_2) : _classifier(new string_array) { -// FUNCDEF("constructor [two strings]"); + FUNCDEF("constructor [two strings]"); *_classifier += class_1; *_classifier += class_2; } @@ -63,7 +63,7 @@ infoton::infoton(const astring &class_1, const astring &class_2, const astring &class_3) : _classifier(new string_array) { -// FUNCDEF("constructor [three strings]"); + FUNCDEF("constructor [three strings]"); *_classifier += class_1; *_classifier += class_2; *_classifier += class_3; @@ -161,7 +161,7 @@ int infoton::fast_pack_overhead(const string_array &classifier) void infoton::fast_pack(byte_array &packed_form, const infoton &to_pack) { -// FUNCDEF("fast_pack"); + FUNCDEF("fast_pack"); structures::attach(packed_form, FAST_PACK_VERSION); // add the tasty version byte as the very first item. structures::pack_array(packed_form, to_pack.classifier()); @@ -185,7 +185,7 @@ void infoton::fast_pack(byte_array &packed_form, const infoton &to_pack) bool infoton::test_fast_unpack(const byte_array &packed_form, int &packed_length) { -// FUNCDEF("test_fast_unpack"); + FUNCDEF("test_fast_unpack"); packed_length = 0; if (!packed_form.length()) return false; diff --git a/octopi/library/octopus/octopus.cpp b/octopi/library/octopus/octopus.cpp index 9ee8d7eb..03ea2438 100644 --- a/octopi/library/octopus/octopus.cpp +++ b/octopi/library/octopus/octopus.cpp @@ -159,7 +159,7 @@ octopus::octopus(const astring &name, int max_per_ent) octopus::~octopus() { -// FUNCDEF("destructor"); + FUNCDEF("destructor"); WHACK(_filters); WHACK(_tentacles); WHACK(_responses); @@ -497,7 +497,7 @@ outcome octopus::evaluate(infoton *request, const octopus_request_id &id, void octopus::periodic_cleaning() { -// FUNCDEF("periodic_cleaning"); + FUNCDEF("periodic_cleaning"); time_stamp next_time; { auto_synchronizer l(*_clean_lock); diff --git a/octopi/library/sockets/internet_address.cpp b/octopi/library/sockets/internet_address.cpp index 73713402..ac6c90ab 100644 --- a/octopi/library/sockets/internet_address.cpp +++ b/octopi/library/sockets/internet_address.cpp @@ -105,7 +105,7 @@ machine_uid internet_address::convert() const bool internet_address::ip_appropriate_number(const astring &to_check, int indy, astring &accum) { -// FUNCDEF("ip_appropriate_number"); + FUNCDEF("ip_appropriate_number"); accum.reset(); for (int i = indy; (i < indy + 3) && (i < to_check.length()); i++) { // make sure it looks like a good number. @@ -127,7 +127,7 @@ bool internet_address::ip_appropriate_number(const astring &to_check, int indy, bool internet_address::has_ip_address(const astring &to_check, astring &ip_found) { -// FUNCDEF("has_ip_address"); + FUNCDEF("has_ip_address"); int nums_seen = 0; ip_found.reset(); for (int i = 0; i < to_check.length(); i++) { diff --git a/octopi/library/sockets/raw_socket.cpp b/octopi/library/sockets/raw_socket.cpp index c149e18b..b3a52196 100644 --- a/octopi/library/sockets/raw_socket.cpp +++ b/octopi/library/sockets/raw_socket.cpp @@ -196,7 +196,7 @@ bool raw_socket::set_keep_alive(basis::un_int socket, bool keep_alive) int raw_socket::select(basis::un_int socket, int mode, int timeout) const { -// FUNCDEF("select [single]"); + FUNCDEF("select [single]"); if (!socket) return SI_ERRONEOUS; fd_set_wrapper read_list, write_list, exceps; int ret = inner_select(socket, mode, timeout, read_list, write_list, exceps); diff --git a/octopi/library/sockets/socket_minder.cpp b/octopi/library/sockets/socket_minder.cpp index 84368cdb..c99aac96 100644 --- a/octopi/library/sockets/socket_minder.cpp +++ b/octopi/library/sockets/socket_minder.cpp @@ -145,7 +145,7 @@ astring socket_minder::text_form() const void socket_minder::snoozy_select() { -// FUNCDEF("snoozy_select"); + FUNCDEF("snoozy_select"); int_array read_sox; int_array write_sox; int_array pending; @@ -264,7 +264,7 @@ bool socket_minder::add_socket_data(int socket, bool server, int server_socket, bool socket_minder::remove_socket_data(int socket) { -// FUNCDEF("remove_socket_data"); + FUNCDEF("remove_socket_data"); auto_synchronizer l(*_lock); for (int i = 0; i < _socket_list->elements(); i++) { if (_socket_list->borrow(i)->_socket == socket) { diff --git a/octopi/library/sockets/tcpip_stack.cpp b/octopi/library/sockets/tcpip_stack.cpp index f45ea6aa..bb144e88 100644 --- a/octopi/library/sockets/tcpip_stack.cpp +++ b/octopi/library/sockets/tcpip_stack.cpp @@ -251,7 +251,7 @@ bool tcpip_stack::enumerate_adapters(machine_uid_array &ip_addresses, sockaddr tcpip_stack::convert(const internet_address &make_from) { -// FUNCDEF("convert [to sockaddr]"); + FUNCDEF("convert [to sockaddr]"); sockaddr_in new_socket; // our socket. memset(&new_socket, 0, sizeof(new_socket)); // clear it out. new_socket.sin_family = AF_INET; @@ -308,7 +308,7 @@ byte_array tcpip_stack::full_resolve(const astring &hostname, bool tcpip_stack::resolve_any(const astring &hostname, internet_address &to_return) const { -// FUNCDEF("resolve_any"); + FUNCDEF("resolve_any"); to_return = internet_address(); if (!hostname) return false; // blank hostnames go nowhere. astring full_host; @@ -324,7 +324,7 @@ bool tcpip_stack::resolve_any(const astring &hostname, astring tcpip_stack::dns_resolve(const astring &hostname) const { -// FUNCDEF("dns_resolve"); + FUNCDEF("dns_resolve"); if (!hostname) return ""; // blank hostnames go nowhere. if (hostname.iequals("local") || hostname.iequals("localhost")) { return "127.0.0.1"; diff --git a/octopi/library/synchronic/list_manager.cpp b/octopi/library/synchronic/list_manager.cpp index 2040295d..8bcacd35 100644 --- a/octopi/library/synchronic/list_manager.cpp +++ b/octopi/library/synchronic/list_manager.cpp @@ -201,7 +201,7 @@ outcome list_manager::consume(infoton &to_chow, void list_manager::expunge(const octopus_entity &formal(to_remove)) { -// FUNCDEF("expunge"); + FUNCDEF("expunge"); } } //namespace. diff --git a/octopi/library/tentacles/encryption_infoton.cpp b/octopi/library/tentacles/encryption_infoton.cpp index 7cec48c7..b6250755 100644 --- a/octopi/library/tentacles/encryption_infoton.cpp +++ b/octopi/library/tentacles/encryption_infoton.cpp @@ -105,7 +105,7 @@ bool encryption_infoton::unpack(byte_array &packed_form) outcome encryption_infoton::prepare_blowfish_key(blowfish_crypto &new_key) { -// FUNCDEF("prepare_blowfish_key"); + FUNCDEF("prepare_blowfish_key"); _encrypted_blowfish_key.reset(); // clean out stuff to create. if (!_public_key.length()) { // wrong type of request being seen or something. @@ -143,7 +143,7 @@ outcome encryption_infoton::prepare_public_key(const rsa_crypto &private_key) outcome encryption_infoton::extract_response(const rsa_crypto &private_key, blowfish_crypto &new_key) const { -// FUNCDEF("extract_response"); + FUNCDEF("extract_response"); if (_success != tentacle::OKAY) return _success; byte_array decrypted; bool worked = private_key.private_decrypt(_encrypted_blowfish_key, decrypted); diff --git a/octopi/library/tentacles/file_transfer_tentacle.cpp b/octopi/library/tentacles/file_transfer_tentacle.cpp index 23eee9de..c004b077 100644 --- a/octopi/library/tentacles/file_transfer_tentacle.cpp +++ b/octopi/library/tentacles/file_transfer_tentacle.cpp @@ -273,14 +273,14 @@ outcome file_transfer_tentacle::add_correspondence } #ifdef DEBUG_FILE_TRANSFER_TENTACLE LOG(astring("adding tree for: ent=") + new_record->_ent.text_form() - + " src=" + new_record->_src_root + " dest=" + new_record->_dest_root); + + " src=" + new_record->_src_root); #endif // calculate size and checksum info for the directory. new_record->_local_dir->calculate( !(_mode & COMPARE_CONTENT_SAMPLE) ); #ifdef DEBUG_FILE_TRANSFER_TENTACLE LOG(astring("done adding tree for: ent=") + new_record->_ent.text_form() - + " src=" + new_record->_src_root + " dest=" + new_record->_dest_root); + + " src=" + new_record->_src_root); #endif _correspondences->append(new_record); diff --git a/octopi/library/tentacles/login_tentacle.cpp b/octopi/library/tentacles/login_tentacle.cpp index 20b34e2a..c26c2f2a 100644 --- a/octopi/library/tentacles/login_tentacle.cpp +++ b/octopi/library/tentacles/login_tentacle.cpp @@ -59,7 +59,7 @@ void login_tentacle::expunge(const octopus_entity &to_remove) outcome login_tentacle::consume(infoton &to_chow, const octopus_request_id &item_id, byte_array &transformed) { -// FUNCDEF("consume"); + FUNCDEF("consume"); transformed.reset(); security_infoton *inf = dynamic_cast(&to_chow); if (!inf) { -- 2.34.1