Esempio n. 1
0
/**
 * If the log is initialized, then add an entry to it. There is no lock
 * protecting the atomicity of checking if the log is allocated and adding the
 * entry.
 *
 * \param entry Value to be added to the log
 */
void logging(const char *entry) {
  if (shared_log) {

#ifdef FORCE
      sleep(1);
#endif

    add_log_entry(shared_log, entry);
  }
}
Esempio n. 2
0
void logging(const char *entry) {
  if (shared_log) {
    add_log_entry(shared_log, entry);
  }
}