X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/blobdiff_plain/5a3e9ff6081cb83873881df9a7bcfc19f9af5e58..dd4a039515e3f14c62beffc23081de5dead98382:/mkrounding.c diff --git a/mkrounding.c b/mkrounding.c index f81d7877..1f3e3b83 100644 --- a/mkrounding.c +++ b/mkrounding.c @@ -1,3 +1,22 @@ +/* + * A pre-compilation helper program to aid in the creation of rounding.h. + * + * Copyright (C) 2007 Wayne Davison + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, visit the http://fsf.org website. + */ + #include "rsync.h" struct test1 { @@ -37,11 +56,27 @@ struct test4 { cnt = 3; } if (cnt) - fprintf(stderr, "Rounding file_extras values in multiples of %d", cnt + 1); + fprintf(stderr, "Rounding file_extras in multiples of %d", cnt + 1); else - fprintf(stderr, "No rounding needed for file_extras values"); + fprintf(stderr, "No rounding needed for file_extras"); fprintf(stderr, " (EXTRA_LEN=%d, FILE_STRUCT_LEN=%d)\n", (int)EXTRA_LEN, (int)FILE_STRUCT_LEN); printf("#define EXTRA_ROUNDING %d\n", cnt); return 0; } + +void *_new_array(UNUSED(unsigned long num), UNUSED(unsigned int size), UNUSED(int use_calloc)) +{ + out_of_memory(""); +} + +void *_realloc_array(UNUSED(void *ptr), UNUSED(unsigned int size), UNUSED(unsigned long num)) +{ + out_of_memory(""); +} + +NORETURN void out_of_memory(UNUSED(const char *str)) +{ + fprintf(stderr, "ERROR: this function should not be called!\n"); + exit(1); +}