diff options
author | aldot <aldot@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2006-03-01 20:14:16 +0000 |
---|---|---|
committer | aldot <aldot@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2006-03-01 20:14:16 +0000 |
commit | 496503369255da68a0975d86cf84d98b39586706 (patch) | |
tree | ae4fa52bf170cb437813abb093a264705e0462ad | |
parent | 5b5c0305447c61a4cc4a0c29a43c2dc2b1befe34 (diff) | |
download | busybox-w32-496503369255da68a0975d86cf84d98b39586706.tar.gz busybox-w32-496503369255da68a0975d86cf84d98b39586706.tar.bz2 busybox-w32-496503369255da68a0975d86cf84d98b39586706.zip |
- fix compilation of sed.
error: static declaration of 'free_and_close_stuff' follows non-static declaration
Tiny whitespace cleanup while at it,
also make sure that we don't use CONFIG_ anymore.
Rob, hope this is ok w/ you..
git-svn-id: svn://busybox.net/trunk/busybox@14399 69ca8d6d-28ef-0310-b511-8ec308f3f277
-rw-r--r-- | editors/sed.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/editors/sed.c b/editors/sed.c index f58f442e8..726ebbd0c 100644 --- a/editors/sed.c +++ b/editors/sed.c | |||
@@ -9,7 +9,7 @@ | |||
9 | * Copyright (C) 2003,2004 by Rob Landley <rob@landley.net> | 9 | * Copyright (C) 2003,2004 by Rob Landley <rob@landley.net> |
10 | * | 10 | * |
11 | * MAINTAINER: Rob Landley <rob@landley.net> | 11 | * MAINTAINER: Rob Landley <rob@landley.net> |
12 | * | 12 | * |
13 | * Licensed under GPLv2 or later, see file LICENSE in this tarball for details. | 13 | * Licensed under GPLv2 or later, see file LICENSE in this tarball for details. |
14 | */ | 14 | */ |
15 | 15 | ||
@@ -76,7 +76,7 @@ typedef struct sed_cmd_s { | |||
76 | regex_t *sub_match; /* For 's/sub_match/string/' */ | 76 | regex_t *sub_match; /* For 's/sub_match/string/' */ |
77 | int beg_line; /* 'sed 1p' 0 == apply commands to all lines */ | 77 | int beg_line; /* 'sed 1p' 0 == apply commands to all lines */ |
78 | int end_line; /* 'sed 1,3p' 0 == one line only. -1 = last line ($) */ | 78 | int end_line; /* 'sed 1,3p' 0 == one line only. -1 = last line ($) */ |
79 | 79 | ||
80 | FILE *file; /* File (sw) command writes to, -1 for none. */ | 80 | FILE *file; /* File (sw) command writes to, -1 for none. */ |
81 | char *string; /* Data string for (saicytb) commands. */ | 81 | char *string; /* Data string for (saicytb) commands. */ |
82 | 82 | ||
@@ -122,8 +122,8 @@ struct append_list { | |||
122 | }; | 122 | }; |
123 | static struct append_list *append_head=NULL, *append_tail=NULL; | 123 | static struct append_list *append_head=NULL, *append_tail=NULL; |
124 | 124 | ||
125 | void free_and_close_stuff(void); | 125 | static void free_and_close_stuff(void); |
126 | #ifdef CONFIG_FEATURE_CLEAN_UP | 126 | #if ENABLE_FEATURE_CLEAN_UP |
127 | static void free_and_close_stuff(void) | 127 | static void free_and_close_stuff(void) |
128 | { | 128 | { |
129 | sed_cmd_t *sed_cmd = sed_cmd_head.next; | 129 | sed_cmd_t *sed_cmd = sed_cmd_head.next; |
@@ -1200,15 +1200,15 @@ extern int sed_main(int argc, char **argv) | |||
1200 | if(-1==(nonstdoutfd=mkstemp(outname))) | 1200 | if(-1==(nonstdoutfd=mkstemp(outname))) |
1201 | bb_error_msg_and_die("no temp file"); | 1201 | bb_error_msg_and_die("no temp file"); |
1202 | nonstdout=fdopen(nonstdoutfd,"w"); | 1202 | nonstdout=fdopen(nonstdoutfd,"w"); |
1203 | 1203 | ||
1204 | /* Set permissions of output file */ | 1204 | /* Set permissions of output file */ |
1205 | 1205 | ||
1206 | fstat(fileno(file),&statbuf); | 1206 | fstat(fileno(file),&statbuf); |
1207 | fchmod(nonstdoutfd,statbuf.st_mode); | 1207 | fchmod(nonstdoutfd,statbuf.st_mode); |
1208 | add_input_file(file); | 1208 | add_input_file(file); |
1209 | process_files(); | 1209 | process_files(); |
1210 | fclose(nonstdout); | 1210 | fclose(nonstdout); |
1211 | 1211 | ||
1212 | nonstdout=stdout; | 1212 | nonstdout=stdout; |
1213 | unlink(argv[i]); | 1213 | unlink(argv[i]); |
1214 | rename(outname,argv[i]); | 1214 | rename(outname,argv[i]); |