add: DEBUG_CFLOW_STATEMENT(cerr << "JACK running; correct position");
context: static void eca_jack_process_timebase_slave(jack_nframes_t nframes, void *arg){  AUDIO_IO_JACK_MANAGER* current = static_cast<AUDIO_IO_JACK_MANAGER*>(arg);  bool need_mute = false;  current->transport_info_rep.valid = static_cast<jack_transport_bits_t>(JackTransportState | JackTransportPosition);  jack_get_transport_info(current->client_repp, &current->transport_info_rep);  /* 1. transport stopped */  if (current->transport_info_rep.state == JackTransportStopped) {    DEBUG_CFLOW_STATEMENT(cerr << "JACK stopped" << endl);    if (current->is_running() == true) {      // DEBUG_CFLOW_STATEMENT(cerr << "eca_jack_process(): running" << endl);      current->engine_repp->command(ECA_ENGINE::ep_stop, 0.0f);      need_mute = true;    }  }  /* 2. transport rolling; run engine if ready */  else {    if (current->is_running() != true) {      if ((current->engine_repp->status() !=	   ECA_ENGINE::engine_status_finished) || 	  (current->transport_info_rep.position < 	   current->engine_repp->current_position_in_samples())) {	current->engine_repp->command(ECA_ENGINE::ep_start, 0.0f);      }      need_mute = true;    }    else {      SAMPLE_SPECS::sample_pos_t enginepos = current->engine_repp->current_position_in_samples();      if (enginepos == current->transport_info_rep.position) {	// DEBUG_CFLOW_STATEMENT(cerr << "JACK running" << endl);	/* execute engine iteration */	eca_jack_process_engine_iteration(nframes, current);	current->trace_position_count_rep = 0;      }      else {	if ((enginepos < current->transport_info_rep.position + current->buffersize() && 	     enginepos - 16 * current->buffersize() < current->transport_info_rep.position) ||	    current->trace_position_count_rep > 8) {	  /* engine position incorrect; request seek to new pos */	  DEBUG_CFLOW_STATEMENT(cerr << endl << "eca_jack_process(): engine curpos '" << 				current->engine_repp->current_position_in_samples() << 				"' doesn't match JACK curpos '" << 				current->transport_info_rep.position << "'!" << endl);	  current->engine_repp->command(ECA_ENGINE::ep_setpos_live_samples, 					current->transport_info_rep.position + 16 * current->buffersize());	  DEBUG_CFLOW_STATEMENT(cerr << "eca_jack_process(): setpos request sent; seeking to "				<< current->transport_info_rep.position + 16 * current->buffersize() << endl);	  if (current->trace_position_count_rep > 8) current->trace_position_count_rep = 0;	}	else {	  /* engine is already seeking to a new pos */	  DEBUG_CFLOW_STATEMENT(cerr << endl 				<< "eca_jack_process(): seek to new pos underway; " 				<< current->transport_info_rep.position				<< " is tcurpos." <<  endl);	  need_mute = true;	}	++current->trace_position_count_rep;	if (current->trace_position_count_rep > 8) {	  ECA_LOG_MSG(ECA_LOGGER::info,		      "audioio_jack_manager(): warning! cannot keep up with JACK position changes!");	}      }    }  }  if (need_mute == true) {    eca_jack_process_mute(nframes, current);  }}