static void go(BufBuilder& bb) { { readlocktry lk("", 1000); if( lk.got() ) { _go(bb); return; } } // starvation on read locks could occur. so if read lock acquisition is slow, try to get a // write lock instead. otherwise writes could use too much RAM. writelock lk; _go(bb); }
static void go() { if( !commitJob.hasWritten() ) return; { readlocktry lk("", 1000); if( lk.got() ) { _go(); return; } } // starvation on read locks could occur. so if read lock acquisition is slow, try to get a // write lock instead. otherwise writes could use too much RAM. writelock lk; _go(); }
/** called when a MongoMMF is closing -- we need to go ahead and group commit in that case before its views disappear */ void closingFileNotification() { if( dbMutex.atLeastReadLocked() ) { _go(); } else { assert( inShutdown() ); if( commitJob.hasWritten() ) { log() << "dur warning files are closing outside locks with writes pending" << endl; } } }
void CommandSet::go() { /* holonomics and shit */ float x_vel = atof(sCmd.next()); float y_vel = atof(sCmd.next()); float r_vel = atof(sCmd.next()); Serial.println(F("A")); #ifdef FW_DEBUG Serial.println(F("Going")); #endif _go(x_vel, y_vel, r_vel); }
void CommandSet::shuntkick() { if (state.grabber_state != Open || state.kicker_state == Kicking) { Serial.println(F("N - shuntkick")); return; } Serial.println(F("A")); #ifdef FW_DEBUG Serial.println(F("shuntkicking")); #endif const pid_t pid = state.shuntkick_handler->id; _go(0, 255, 0); processes.enable(pid); processes.forward(pid); }
static void handle(int sig) { _go(1); exit(0); }
int _start(char* argstr, long arglen, struct ExecBase* sysbase) { SysBase = (Library*)sysbase; return _go(); }
int HttpClient::post( string url , string data , Result * result ) { return _go( "POST" , url , data.c_str() , result ); }
int HttpClient::get( string url , Result * result ) { return _go( "GET" , url , 0 , result ); }
int HttpClient::post( const std::string& url , const std::string& data , Result * result ) { return _go( "POST" , url , data.c_str() , result ); }
int HttpClient::get( const std::string& url , Result * result ) { return _go( "GET" , url , 0 , result ); }