printf("%s\n", path.c_str());
- file_info["mode"] = encode_int(stat_buf.st_mode & 07777);
+ file_info["mode"] = encode_int(stat_buf.st_mode & 07777, 8);
file_info["mtime"] = encode_int(stat_buf.st_mtime);
file_info["user"] = encode_int(stat_buf.st_uid);
file_info["group"] = encode_int(stat_buf.st_gid);
}
}
- if (argc < optind + 2) {
- usage(argv[0]);
- return 1;
- }
-
searches.push_back(".");
if (optind == argc) {
add_include(".");
desc_filename = desc_filename + desc_buf + ".lbs";
std::ofstream descriptor(desc_filename.c_str());
- descriptor << "Format: LBS Snapshot v0.1\n";
+ descriptor << "Format: LBS Snapshot v0.2\n";
descriptor << "Producer: LBS " << lbs_version << "\n";
strftime(desc_buf, sizeof(desc_buf), "%Y-%m-%d %H:%M:%S %z", &time_buf);
descriptor << "Date: " << desc_buf << "\n";