| /////////////////////////////////////////////////////////////////////////////// |
| /// \brief Repeats given string given times |
| /// This program can be useful when debugging run-length encoder in |
| /// the Subblock filter, especially the condition when repeat count |
| /// doesn't fit into 28-bit integer. |
| // This file has been put into the public domain. |
| // You can do whatever you want with this file. |
| /////////////////////////////////////////////////////////////////////////////// |
| main(int argc, char **argv) |
| fprintf(stderr, "Usage: %s COUNT STRING\n", argv[0]); |
| unsigned long long count = strtoull(argv[1], NULL, 10); |
| const size_t size = strlen(argv[2]); |
| fwrite(argv[2], 1, size, stdout); |
| return !!(ferror(stdout) || fclose(stdout)); |