Daniel Kahn Gillmor <dkg@fifthhorseman.net> writes: > + if (argc < 2) { > + std::cerr << "usage: ghost-report xapian-dir" << std::endl; > + } > + > + Xapian::Database db(argv[1]); > + std::cout << db.get_termfreq("Tghost") << std::endl; > +} It's completely my fault, but this should have an exit(1) after printing the error message.