2 * $OpenBSD: util.h,v 1.15 2005/06/20 07:14:06 otto Exp $
3 * $DragonFly: src/usr.bin/patch/util.h,v 1.2 2007/09/29 23:11:10 swildner Exp $
4 * $NetBSD: util.h,v 1.12 2011/09/06 18:25:14 joerg Exp $
8 * patch - a program to apply diffs to original files
10 * Copyright 1986, Larry Wall
12 * Redistribution and use in source and binary forms, with or without
13 * modification, are permitted provided that the following condition is met:
14 * 1. Redistributions of source code must retain the above copyright notice,
15 * this condition and the following disclaimer.
17 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY
18 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
19 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
20 * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR
21 * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
22 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
23 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
24 * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
29 * -C option added in 1998, original code by Marc Espie, based on FreeBSD
33 char *fetchname(const char *, bool *, int);
34 char *checked_in(char *);
35 int backup_file(const char *);
36 int move_file(const char *, const char *);
37 int copy_file(const char *, const char *);
38 void say(const char *, ...) __printflike(1, 2);
39 void fatal(const char *, ...) __printflike(1, 2) __dead
;
40 void pfatal(const char *, ...) __printflike(1, 2) __dead
;
41 void ask(const char *, ...) __printflike(1, 2);
42 char *savestr(const char *);
43 void set_signals(int);
44 void ignore_signals(void);
45 void makedirs(const char *, bool);
46 void version(void) __dead
;
47 void my_exit(int) __dead
;
50 extern int mkpath(char *);