util.c (250972) | util.c (250975) |
---|---|
1/*- 2 * Copyright 1986, Larry Wall 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following condition is met: 6 * 1. Redistributions of source code must retain the above copyright notice, 7 * this condition and the following disclaimer. 8 * --- 10 unchanged lines hidden (view full) --- 19 * SUCH DAMAGE. 20 * 21 * patch - a program to apply diffs to original files 22 * 23 * -C option added in 1998, original code by Marc Espie, based on FreeBSD 24 * behaviour 25 * 26 * $OpenBSD: util.c,v 1.35 2010/07/24 01:10:12 ray Exp $ | 1/*- 2 * Copyright 1986, Larry Wall 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following condition is met: 6 * 1. Redistributions of source code must retain the above copyright notice, 7 * this condition and the following disclaimer. 8 * --- 10 unchanged lines hidden (view full) --- 19 * SUCH DAMAGE. 20 * 21 * patch - a program to apply diffs to original files 22 * 23 * -C option added in 1998, original code by Marc Espie, based on FreeBSD 24 * behaviour 25 * 26 * $OpenBSD: util.c,v 1.35 2010/07/24 01:10:12 ray Exp $ |
27 * $FreeBSD: head/usr.bin/patch/util.c 250972 2013-05-24 18:54:52Z se $ | 27 * $FreeBSD: head/usr.bin/patch/util.c 250975 2013-05-25 07:17:16Z gjb $ |
28 */ 29 30#include <sys/param.h> 31#include <sys/stat.h> 32 33#include <ctype.h> 34#include <errno.h> 35#include <fcntl.h> --- 371 unchanged lines hidden (view full) --- 407 return file; 408 409 return NULL; 410} 411 412void 413version(void) 414{ | 28 */ 29 30#include <sys/param.h> 31#include <sys/stat.h> 32 33#include <ctype.h> 34#include <errno.h> 35#include <fcntl.h> --- 371 unchanged lines hidden (view full) --- 407 return file; 408 409 return NULL; 410} 411 412void 413version(void) 414{ |
415 fprintf(stderr, "patch 2.0-12u9 FreeBSD\n"); | 415 fprintf(stderr, "patch 2.0-12u8 FreeBSD\n"); |
416 my_exit(EXIT_SUCCESS); 417} 418 419/* 420 * Exit with cleanup. 421 */ 422void 423my_exit(int status) 424{ 425 unlink(TMPINNAME); 426 if (!toutkeep) 427 unlink(TMPOUTNAME); 428 if (!trejkeep) 429 unlink(TMPREJNAME); 430 unlink(TMPPATNAME); 431 exit(status); 432} | 416 my_exit(EXIT_SUCCESS); 417} 418 419/* 420 * Exit with cleanup. 421 */ 422void 423my_exit(int status) 424{ 425 unlink(TMPINNAME); 426 if (!toutkeep) 427 unlink(TMPOUTNAME); 428 if (!trejkeep) 429 unlink(TMPREJNAME); 430 unlink(TMPPATNAME); 431 exit(status); 432} |