lock ml(count_mutex);
int x = lid[0] & 0x0f;
if (ct[x] != 0) {
- cout << "error: server granted " << lid << " twice" << endl;
- cerr << "error: server granted " << lid << " twice" << endl;
+ LOG_NONMEMBER("error: server granted " << lid << " twice");
exit(1);
}
ct[x] += 1;
lock ml(count_mutex);
int x = lid[0] & 0x0f;
if (ct[x] != 1) {
- cerr << "error: client released un-held lock " << lid << endl;
+ LOG_NONMEMBER("error: client released un-held lock " << lid);
exit(1);
}
ct[x] -= 1;
srandom((uint32_t)getpid());
if (argc < 2) {
- cerr << "Usage: " << argv[0] << " [host:]port [test]" << endl;
+ LOG_NONMEMBER("Usage: " << argv[0] << " [host:]port [test]");
exit(1);
}