1246074Sgabor/*- 2246074Sgabor * Copyright 1986, Larry Wall 3246074Sgabor * 4246074Sgabor * Redistribution and use in source and binary forms, with or without 5246074Sgabor * modification, are permitted provided that the following condition is met: 6246074Sgabor * 1. Redistributions of source code must retain the above copyright notice, 7246074Sgabor * this condition and the following disclaimer. 8246074Sgabor * 9246074Sgabor * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY 10246074Sgabor * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 11246074Sgabor * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 12246074Sgabor * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR 13246074Sgabor * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 14246074Sgabor * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 15246074Sgabor * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 16246074Sgabor * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 17246074Sgabor * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 18246074Sgabor * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 19246074Sgabor * SUCH DAMAGE. 20246074Sgabor * 21246074Sgabor * patch - a program to apply diffs to original files 22246074Sgabor * 23246074Sgabor * -C option added in 1998, original code by Marc Espie, based on FreeBSD 24246074Sgabor * behaviour 25246074Sgabor * 26246074Sgabor * $OpenBSD: util.h,v 1.15 2005/06/20 07:14:06 otto Exp $ 27246091Sdelphij * $FreeBSD$ 28246074Sgabor */ 29246074Sgabor 30246074Sgaborchar *fetchname(const char *, bool *, int); 31246074Sgaborchar *checked_in(char *); 32246074Sgaborint backup_file(const char *); 33246074Sgaborint move_file(const char *, const char *); 34246074Sgaborint copy_file(const char *, const char *); 35246074Sgaborvoid say(const char *, ...) 36246074Sgabor __attribute__((__format__(__printf__, 1, 2))); 37246074Sgaborvoid fatal(const char *, ...) 38246074Sgabor __attribute__((__format__(__printf__, 1, 2))); 39246074Sgaborvoid pfatal(const char *, ...) 40246074Sgabor __attribute__((__format__(__printf__, 1, 2))); 41246074Sgaborvoid ask(const char *, ...) 42246074Sgabor __attribute__((__format__(__printf__, 1, 2))); 43246074Sgaborchar *savestr(const char *); 44246074Sgaborvoid set_signals(int); 45246074Sgaborvoid ignore_signals(void); 46246074Sgaborvoid makedirs(const char *, bool); 47246074Sgaborvoid version(void); 48246074Sgaborvoid my_exit(int) __attribute__((noreturn)); 49246074Sgabor 50246074Sgabor/* in mkpath.c */ 51246074Sgaborextern int mkpath(char *); 52