Merge lp:~percona-dev/percona-xtrabackup/exit_codes into lp:percona-xtrabackup/2.0
- exit_codes
- Merge into 2.0
Proposed by
Aleksandr Kuzminsky
Status: | Merged |
---|---|
Approved by: | Vadim Tkachenko |
Approved revision: | no longer in the source branch. |
Merged at revision: | 208 |
Proposed branch: | lp:~percona-dev/percona-xtrabackup/exit_codes |
Merge into: | lp:percona-xtrabackup/2.0 |
Diff against target: |
329 lines (+37/-37) 1 file modified
xtrabackup.c (+37/-37) |
To merge this branch: | bzr merge lp:~percona-dev/percona-xtrabackup/exit_codes |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Vadim Tkachenko | Approve | ||
Review via email: mp+40469@code.launchpad.net |
Commit message
Description of the change
use macroses EXIT_SUCCESS and EXIT_FAILURE as exit codes
To post a comment you must log in.
Revision history for this message
Baron Schwartz (baron-xaprb) wrote : | # |
In the original code, there were three magic numbers: 0, 1, and -1. There seemed to be an important difference between -1 and 1, but I have not seen an explanation of it. I tried to document my best guess: http://
I am not sure that both 1 and -1 should be replaced with a single exit code. Maybe we need Yasufumi to explain the difference. It might be important for scripting, cron jobs, etc. At least we should document why it was wrong for them to be different.
Revision history for this message
Vadim Tkachenko (vadim-tk) : | # |
review:
Needs Fixing
Revision history for this message
Yasufumi Kinoshita (yasufumi-kinoshita) wrote : | # |
If innobackupex doesn't depend on the code, the change should be OK.
Revision history for this message
Vadim Tkachenko (vadim-tk) wrote : | # |
I do not see it used differently in innobackupex
review:
Approve
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'xtrabackup.c' | |||
2 | --- xtrabackup.c 2010-11-05 07:48:55 +0000 | |||
3 | +++ xtrabackup.c 2010-11-09 18:21:09 +0000 | |||
4 | @@ -1062,7 +1062,7 @@ | |||
5 | 1062 | break; | 1062 | break; |
6 | 1063 | case '?': | 1063 | case '?': |
7 | 1064 | usage(); | 1064 | usage(); |
9 | 1065 | exit(0); | 1065 | exit(EXIT_SUCCESS); |
10 | 1066 | break; | 1066 | break; |
11 | 1067 | default: | 1067 | default: |
12 | 1068 | break; | 1068 | break; |
13 | @@ -1612,7 +1612,7 @@ | |||
14 | 1612 | bzero((G_PTR) &mysql_tmpdir_list, sizeof(mysql_tmpdir_list)); | 1612 | bzero((G_PTR) &mysql_tmpdir_list, sizeof(mysql_tmpdir_list)); |
15 | 1613 | 1613 | ||
16 | 1614 | if (init_tmpdir(&mysql_tmpdir_list, opt_mysql_tmpdir)) | 1614 | if (init_tmpdir(&mysql_tmpdir_list, opt_mysql_tmpdir)) |
18 | 1615 | exit(1); | 1615 | exit(EXIT_FAILURE); |
19 | 1616 | 1616 | ||
20 | 1617 | /* dummy for initialize all_charsets[] */ | 1617 | /* dummy for initialize all_charsets[] */ |
21 | 1618 | get_charset_name(0); | 1618 | get_charset_name(0); |
22 | @@ -2908,7 +2908,7 @@ | |||
23 | 2908 | if (my_setwd(mysql_real_data_home,MYF(MY_WME))) | 2908 | if (my_setwd(mysql_real_data_home,MYF(MY_WME))) |
24 | 2909 | { | 2909 | { |
25 | 2910 | fprintf(stderr, "xtrabackup: cannot my_setwd %s\n", mysql_real_data_home); | 2910 | fprintf(stderr, "xtrabackup: cannot my_setwd %s\n", mysql_real_data_home); |
27 | 2911 | exit(1); | 2911 | exit(EXIT_FAILURE); |
28 | 2912 | } | 2912 | } |
29 | 2913 | fprintf(stderr, "xtrabackup: cd to %s\n", mysql_real_data_home); | 2913 | fprintf(stderr, "xtrabackup: cd to %s\n", mysql_real_data_home); |
30 | 2914 | 2914 | ||
31 | @@ -2921,7 +2921,7 @@ | |||
32 | 2921 | 2921 | ||
33 | 2922 | /* initialize components */ | 2922 | /* initialize components */ |
34 | 2923 | if(innodb_init_param()) | 2923 | if(innodb_init_param()) |
36 | 2924 | exit(1); | 2924 | exit(EXIT_FAILURE); |
37 | 2925 | 2925 | ||
38 | 2926 | if (srv_file_flush_method_str == NULL) { | 2926 | if (srv_file_flush_method_str == NULL) { |
39 | 2927 | /* These are the default options */ | 2927 | /* These are the default options */ |
40 | @@ -2968,7 +2968,7 @@ | |||
41 | 2968 | fprintf(stderr, | 2968 | fprintf(stderr, |
42 | 2969 | "xtrabackup: Unrecognized value %s for innodb_flush_method\n", | 2969 | "xtrabackup: Unrecognized value %s for innodb_flush_method\n", |
43 | 2970 | srv_file_flush_method_str); | 2970 | srv_file_flush_method_str); |
45 | 2971 | exit(1); | 2971 | exit(EXIT_FAILURE); |
46 | 2972 | } | 2972 | } |
47 | 2973 | 2973 | ||
48 | 2974 | #ifndef INNODB_VERSION_SHORT | 2974 | #ifndef INNODB_VERSION_SHORT |
49 | @@ -3105,13 +3105,13 @@ | |||
50 | 3105 | "xtrabackup: remove old data files which contain your precious data!\n"); | 3105 | "xtrabackup: remove old data files which contain your precious data!\n"); |
51 | 3106 | 3106 | ||
52 | 3107 | //return((int) err); | 3107 | //return((int) err); |
54 | 3108 | exit(1); | 3108 | exit(EXIT_FAILURE); |
55 | 3109 | } | 3109 | } |
56 | 3110 | 3110 | ||
57 | 3111 | /* create_new_db must not be TRUE.. */ | 3111 | /* create_new_db must not be TRUE.. */ |
58 | 3112 | if (create_new_db) { | 3112 | if (create_new_db) { |
59 | 3113 | fprintf(stderr, "xtrabackup: Something wrong with source files...\n"); | 3113 | fprintf(stderr, "xtrabackup: Something wrong with source files...\n"); |
61 | 3114 | exit(1); | 3114 | exit(EXIT_FAILURE); |
62 | 3115 | } | 3115 | } |
63 | 3116 | 3116 | ||
64 | 3117 | for (i = 0; i < srv_n_log_files; i++) { | 3117 | for (i = 0; i < srv_n_log_files; i++) { |
65 | @@ -3120,7 +3120,7 @@ | |||
66 | 3120 | if (err != DB_SUCCESS) { | 3120 | if (err != DB_SUCCESS) { |
67 | 3121 | 3121 | ||
68 | 3122 | //return((int) err); | 3122 | //return((int) err); |
70 | 3123 | exit(1); | 3123 | exit(EXIT_FAILURE); |
71 | 3124 | } | 3124 | } |
72 | 3125 | 3125 | ||
73 | 3126 | if (log_file_created) { | 3126 | if (log_file_created) { |
74 | @@ -3139,14 +3139,14 @@ | |||
75 | 3139 | "xtrabackup: and start the database again.\n"); | 3139 | "xtrabackup: and start the database again.\n"); |
76 | 3140 | 3140 | ||
77 | 3141 | //return(DB_ERROR); | 3141 | //return(DB_ERROR); |
79 | 3142 | exit(1); | 3142 | exit(EXIT_FAILURE); |
80 | 3143 | } | 3143 | } |
81 | 3144 | } | 3144 | } |
82 | 3145 | 3145 | ||
83 | 3146 | /* log_file_created must not be TRUE, if online */ | 3146 | /* log_file_created must not be TRUE, if online */ |
84 | 3147 | if (log_file_created) { | 3147 | if (log_file_created) { |
85 | 3148 | fprintf(stderr, "xtrabackup: Something wrong with source files...\n"); | 3148 | fprintf(stderr, "xtrabackup: Something wrong with source files...\n"); |
87 | 3149 | exit(1); | 3149 | exit(EXIT_FAILURE); |
88 | 3150 | } | 3150 | } |
89 | 3151 | 3151 | ||
90 | 3152 | fil_load_single_table_tablespaces(); | 3152 | fil_load_single_table_tablespaces(); |
91 | @@ -3159,7 +3159,7 @@ | |||
92 | 3159 | if (!my_stat(xtrabackup_target_dir,&stat_info,MYF(0)) | 3159 | if (!my_stat(xtrabackup_target_dir,&stat_info,MYF(0)) |
93 | 3160 | && (my_mkdir(xtrabackup_target_dir,0777,MYF(0)) < 0)){ | 3160 | && (my_mkdir(xtrabackup_target_dir,0777,MYF(0)) < 0)){ |
94 | 3161 | fprintf(stderr,"xtrabackup: Error: cannot mkdir %d: %s\n",my_errno,xtrabackup_target_dir); | 3161 | fprintf(stderr,"xtrabackup: Error: cannot mkdir %d: %s\n",my_errno,xtrabackup_target_dir); |
96 | 3162 | exit(1); | 3162 | exit(EXIT_FAILURE); |
97 | 3163 | } | 3163 | } |
98 | 3164 | 3164 | ||
99 | 3165 | } else { | 3165 | } else { |
100 | @@ -3204,7 +3204,7 @@ | |||
101 | 3204 | 3204 | ||
102 | 3205 | if (err != DB_SUCCESS) { | 3205 | if (err != DB_SUCCESS) { |
103 | 3206 | 3206 | ||
105 | 3207 | exit(1); | 3207 | exit(EXIT_FAILURE); |
106 | 3208 | } | 3208 | } |
107 | 3209 | 3209 | ||
108 | 3210 | log_group_read_checkpoint_info(max_cp_group, max_cp_field); | 3210 | log_group_read_checkpoint_info(max_cp_group, max_cp_field); |
109 | @@ -3226,7 +3226,7 @@ | |||
110 | 3226 | 3226 | ||
111 | 3227 | if (err != DB_SUCCESS) { | 3227 | if (err != DB_SUCCESS) { |
112 | 3228 | 3228 | ||
114 | 3229 | exit(1); | 3229 | exit(EXIT_FAILURE); |
115 | 3230 | } | 3230 | } |
116 | 3231 | 3231 | ||
117 | 3232 | log_group_read_checkpoint_info(max_cp_group, max_cp_field); | 3232 | log_group_read_checkpoint_info(max_cp_group, max_cp_field); |
118 | @@ -3259,7 +3259,7 @@ | |||
119 | 3259 | fprintf(stderr, | 3259 | fprintf(stderr, |
120 | 3260 | "xtrabackup: error: cannot open %s\n", | 3260 | "xtrabackup: error: cannot open %s\n", |
121 | 3261 | dst_log_path); | 3261 | dst_log_path); |
123 | 3262 | exit(1); | 3262 | exit(EXIT_FAILURE); |
124 | 3263 | } | 3263 | } |
125 | 3264 | 3264 | ||
126 | 3265 | #ifdef USE_POSIX_FADVISE | 3265 | #ifdef USE_POSIX_FADVISE |
127 | @@ -3292,7 +3292,7 @@ | |||
128 | 3292 | if (!success) { | 3292 | if (!success) { |
129 | 3293 | if (dst_log != -1) | 3293 | if (dst_log != -1) |
130 | 3294 | os_file_close(dst_log); | 3294 | os_file_close(dst_log); |
132 | 3295 | exit(1); | 3295 | exit(EXIT_FAILURE); |
133 | 3296 | } | 3296 | } |
134 | 3297 | 3297 | ||
135 | 3298 | /* start flag */ | 3298 | /* start flag */ |
136 | @@ -3311,7 +3311,7 @@ | |||
137 | 3311 | 3311 | ||
138 | 3312 | /* copy log file by current position */ | 3312 | /* copy log file by current position */ |
139 | 3313 | if(xtrabackup_copy_logfile(checkpoint_lsn_start, FALSE)) | 3313 | if(xtrabackup_copy_logfile(checkpoint_lsn_start, FALSE)) |
141 | 3314 | exit(1); | 3314 | exit(EXIT_FAILURE); |
142 | 3315 | 3315 | ||
143 | 3316 | 3316 | ||
144 | 3317 | os_thread_create(log_copying_thread, NULL, &log_copying_thread_id); | 3317 | os_thread_create(log_copying_thread, NULL, &log_copying_thread_id); |
145 | @@ -3352,7 +3352,7 @@ | |||
146 | 3352 | && (my_mkdir(path,0777,MYF(0)) < 0)){ | 3352 | && (my_mkdir(path,0777,MYF(0)) < 0)){ |
147 | 3353 | 3353 | ||
148 | 3354 | fprintf(stderr,"xtrabackup: Error: cannot mkdir %d: %s\n",my_errno,path); | 3354 | fprintf(stderr,"xtrabackup: Error: cannot mkdir %d: %s\n",my_errno,path); |
150 | 3355 | exit(1); | 3355 | exit(EXIT_FAILURE); |
151 | 3356 | } | 3356 | } |
152 | 3357 | } | 3357 | } |
153 | 3358 | 3358 | ||
154 | @@ -3365,7 +3365,7 @@ | |||
155 | 3365 | if(xtrabackup_copy_datafile(node)) { | 3365 | if(xtrabackup_copy_datafile(node)) { |
156 | 3366 | if(node->space->id == 0) { | 3366 | if(node->space->id == 0) { |
157 | 3367 | fprintf(stderr,"xtrabackup: Error: failed to copy system datafile.\n"); | 3367 | fprintf(stderr,"xtrabackup: Error: failed to copy system datafile.\n"); |
159 | 3368 | exit(1); | 3368 | exit(EXIT_FAILURE); |
160 | 3369 | } else { | 3369 | } else { |
161 | 3370 | printf("xtrabackup: Warining: failed to copy, but continuing.\n"); | 3370 | printf("xtrabackup: Warining: failed to copy, but continuing.\n"); |
162 | 3371 | } | 3371 | } |
163 | @@ -3496,7 +3496,7 @@ | |||
164 | 3496 | 3496 | ||
165 | 3497 | if (!log_copying_succeed) { | 3497 | if (!log_copying_succeed) { |
166 | 3498 | fprintf(stderr, "xtrabackup: Error: log_copying_thread failed.\n"); | 3498 | fprintf(stderr, "xtrabackup: Error: log_copying_thread failed.\n"); |
168 | 3499 | exit(1); | 3499 | exit(EXIT_FAILURE); |
169 | 3500 | } | 3500 | } |
170 | 3501 | 3501 | ||
171 | 3502 | if (!xtrabackup_stream) | 3502 | if (!xtrabackup_stream) |
172 | @@ -3793,7 +3793,7 @@ | |||
173 | 3793 | if (my_setwd(mysql_real_data_home,MYF(MY_WME))) | 3793 | if (my_setwd(mysql_real_data_home,MYF(MY_WME))) |
174 | 3794 | { | 3794 | { |
175 | 3795 | fprintf(stderr, "xtrabackup: cannot my_setwd %s\n", mysql_real_data_home); | 3795 | fprintf(stderr, "xtrabackup: cannot my_setwd %s\n", mysql_real_data_home); |
177 | 3796 | exit(1); | 3796 | exit(EXIT_FAILURE); |
178 | 3797 | } | 3797 | } |
179 | 3798 | fprintf(stderr, "xtrabackup: cd to %s\n", mysql_real_data_home); | 3798 | fprintf(stderr, "xtrabackup: cd to %s\n", mysql_real_data_home); |
180 | 3799 | 3799 | ||
181 | @@ -3807,14 +3807,14 @@ | |||
182 | 3807 | 3807 | ||
183 | 3808 | /* initialize components */ | 3808 | /* initialize components */ |
184 | 3809 | if(innodb_init_param()) | 3809 | if(innodb_init_param()) |
186 | 3810 | exit(1); | 3810 | exit(EXIT_FAILURE); |
187 | 3811 | 3811 | ||
188 | 3812 | fprintf(stderr, "xtrabackup: Starting 'read-only' InnoDB instance to gather index statistics.\n" | 3812 | fprintf(stderr, "xtrabackup: Starting 'read-only' InnoDB instance to gather index statistics.\n" |
189 | 3813 | "xtrabackup: Using %lld bytes for buffer pool (set by --use-memory parameter)\n", | 3813 | "xtrabackup: Using %lld bytes for buffer pool (set by --use-memory parameter)\n", |
190 | 3814 | xtrabackup_use_memory); | 3814 | xtrabackup_use_memory); |
191 | 3815 | 3815 | ||
192 | 3816 | if(innodb_init()) | 3816 | if(innodb_init()) |
194 | 3817 | exit(1); | 3817 | exit(EXIT_FAILURE); |
195 | 3818 | 3818 | ||
196 | 3819 | fprintf(stdout, "\n\n<INDEX STATISTICS>\n"); | 3819 | fprintf(stdout, "\n\n<INDEX STATISTICS>\n"); |
197 | 3820 | 3820 | ||
198 | @@ -4030,7 +4030,7 @@ | |||
199 | 4030 | 4030 | ||
200 | 4031 | /* shutdown InnoDB */ | 4031 | /* shutdown InnoDB */ |
201 | 4032 | if(innodb_end()) | 4032 | if(innodb_end()) |
203 | 4033 | exit(1); | 4033 | exit(EXIT_FAILURE); |
204 | 4034 | } | 4034 | } |
205 | 4035 | 4035 | ||
206 | 4036 | /* ================= prepare ================= */ | 4036 | /* ================= prepare ================= */ |
207 | @@ -4742,7 +4742,7 @@ | |||
208 | 4742 | if (my_setwd(xtrabackup_real_target_dir,MYF(MY_WME))) | 4742 | if (my_setwd(xtrabackup_real_target_dir,MYF(MY_WME))) |
209 | 4743 | { | 4743 | { |
210 | 4744 | fprintf(stderr, "xtrabackup: cannot my_setwd %s\n", xtrabackup_real_target_dir); | 4744 | fprintf(stderr, "xtrabackup: cannot my_setwd %s\n", xtrabackup_real_target_dir); |
212 | 4745 | exit(1); | 4745 | exit(EXIT_FAILURE); |
213 | 4746 | } | 4746 | } |
214 | 4747 | fprintf(stderr, "xtrabackup: cd to %s\n", xtrabackup_real_target_dir); | 4747 | fprintf(stderr, "xtrabackup: cd to %s\n", xtrabackup_real_target_dir); |
215 | 4748 | 4748 | ||
216 | @@ -4771,14 +4771,14 @@ | |||
217 | 4771 | if (xtrabackup_incremental) { | 4771 | if (xtrabackup_incremental) { |
218 | 4772 | fprintf(stderr, | 4772 | fprintf(stderr, |
219 | 4773 | "xtrabackup: error: applying incremental backup needs target prepared.\n"); | 4773 | "xtrabackup: error: applying incremental backup needs target prepared.\n"); |
221 | 4774 | exit(1); | 4774 | exit(EXIT_FAILURE); |
222 | 4775 | } | 4775 | } |
223 | 4776 | skip_check: | 4776 | skip_check: |
224 | 4777 | if (xtrabackup_incremental | 4777 | if (xtrabackup_incremental |
225 | 4778 | && ut_dulint_cmp(metadata_to_lsn, incremental_lsn) < 0) { | 4778 | && ut_dulint_cmp(metadata_to_lsn, incremental_lsn) < 0) { |
226 | 4779 | fprintf(stderr, | 4779 | fprintf(stderr, |
227 | 4780 | "xtrabackup: error: This incremental backup seems to be too new for the target.\n"); | 4780 | "xtrabackup: error: This incremental backup seems to be too new for the target.\n"); |
229 | 4781 | exit(1); | 4781 | exit(EXIT_FAILURE); |
230 | 4782 | } | 4782 | } |
231 | 4783 | } | 4783 | } |
232 | 4784 | 4784 | ||
233 | @@ -5123,7 +5123,7 @@ | |||
234 | 5123 | os_io_init_simple(); | 5123 | os_io_init_simple(); |
235 | 5124 | 5124 | ||
236 | 5125 | if(xtrabackup_close_temp_log(TRUE)) | 5125 | if(xtrabackup_close_temp_log(TRUE)) |
238 | 5126 | exit(1); | 5126 | exit(EXIT_FAILURE); |
239 | 5127 | 5127 | ||
240 | 5128 | /* output to metadata file */ | 5128 | /* output to metadata file */ |
241 | 5129 | { | 5129 | { |
242 | @@ -5166,7 +5166,7 @@ | |||
243 | 5166 | error: | 5166 | error: |
244 | 5167 | xtrabackup_close_temp_log(FALSE); | 5167 | xtrabackup_close_temp_log(FALSE); |
245 | 5168 | 5168 | ||
247 | 5169 | exit(1); | 5169 | exit(EXIT_FAILURE); |
248 | 5170 | } | 5170 | } |
249 | 5171 | 5171 | ||
250 | 5172 | /* ================= main =================== */ | 5172 | /* ================= main =================== */ |
251 | @@ -5227,7 +5227,7 @@ | |||
252 | 5227 | if (!xtrabackup_print_param) | 5227 | if (!xtrabackup_print_param) |
253 | 5228 | usage(); | 5228 | usage(); |
254 | 5229 | printf("\nxtrabackup: Error: Please set parameter 'datadir'\n"); | 5229 | printf("\nxtrabackup: Error: Please set parameter 'datadir'\n"); |
256 | 5230 | exit(-1); | 5230 | exit(EXIT_FAILURE); |
257 | 5231 | } | 5231 | } |
258 | 5232 | 5232 | ||
259 | 5233 | if (xtrabackup_tables) { | 5233 | if (xtrabackup_tables) { |
260 | @@ -5284,7 +5284,7 @@ | |||
261 | 5284 | fp = fopen(xtrabackup_tables_file,"r"); | 5284 | fp = fopen(xtrabackup_tables_file,"r"); |
262 | 5285 | if (!fp) { | 5285 | if (!fp) { |
263 | 5286 | fprintf(stderr, "xtrabackup: cannot open %s\n", xtrabackup_tables_file); | 5286 | fprintf(stderr, "xtrabackup: cannot open %s\n", xtrabackup_tables_file); |
265 | 5287 | exit(-1); | 5287 | exit(EXIT_FAILURE); |
266 | 5288 | } | 5288 | } |
267 | 5289 | for (;;) { | 5289 | for (;;) { |
268 | 5290 | xtrabackup_tables_t* table; | 5290 | xtrabackup_tables_t* table; |
269 | @@ -5363,7 +5363,7 @@ | |||
270 | 5363 | if (error) { | 5363 | if (error) { |
271 | 5364 | fprintf(stderr, "xtrabackup: value '%s' may be wrong format for incremental option.\n", | 5364 | fprintf(stderr, "xtrabackup: value '%s' may be wrong format for incremental option.\n", |
272 | 5365 | xtrabackup_incremental); | 5365 | xtrabackup_incremental); |
274 | 5366 | exit(-1); | 5366 | exit(EXIT_FAILURE); |
275 | 5367 | } | 5367 | } |
276 | 5368 | 5368 | ||
277 | 5369 | /* allocate buffer for incremental backup (4096 pages) */ | 5369 | /* allocate buffer for incremental backup (4096 pages) */ |
278 | @@ -5378,7 +5378,7 @@ | |||
279 | 5378 | fprintf(stderr, | 5378 | fprintf(stderr, |
280 | 5379 | "xtrabackup: error: failed to read metadata from %s\n", | 5379 | "xtrabackup: error: failed to read metadata from %s\n", |
281 | 5380 | filename); | 5380 | filename); |
283 | 5381 | exit(-1); | 5381 | exit(EXIT_FAILURE); |
284 | 5382 | } | 5382 | } |
285 | 5383 | 5383 | ||
286 | 5384 | incremental_lsn = metadata_to_lsn; | 5384 | incremental_lsn = metadata_to_lsn; |
287 | @@ -5396,7 +5396,7 @@ | |||
288 | 5396 | fprintf(stderr, | 5396 | fprintf(stderr, |
289 | 5397 | "xtrabackup: error: failed to read metadata from %s\n", | 5397 | "xtrabackup: error: failed to read metadata from %s\n", |
290 | 5398 | filename); | 5398 | filename); |
292 | 5399 | exit(-1); | 5399 | exit(EXIT_FAILURE); |
293 | 5400 | } | 5400 | } |
294 | 5401 | 5401 | ||
295 | 5402 | incremental_lsn = metadata_from_lsn; | 5402 | incremental_lsn = metadata_from_lsn; |
296 | @@ -5420,7 +5420,7 @@ | |||
297 | 5420 | bzero((G_PTR) &mysql_tmpdir_list, sizeof(mysql_tmpdir_list)); | 5420 | bzero((G_PTR) &mysql_tmpdir_list, sizeof(mysql_tmpdir_list)); |
298 | 5421 | 5421 | ||
299 | 5422 | if (init_tmpdir(&mysql_tmpdir_list, opt_mysql_tmpdir)) | 5422 | if (init_tmpdir(&mysql_tmpdir_list, opt_mysql_tmpdir)) |
301 | 5423 | exit(1); | 5423 | exit(EXIT_FAILURE); |
302 | 5424 | 5424 | ||
303 | 5425 | printf("# This MySQL options file was generated by XtraBackup.\n"); | 5425 | printf("# This MySQL options file was generated by XtraBackup.\n"); |
304 | 5426 | printf("[mysqld]\n"); | 5426 | printf("[mysqld]\n"); |
305 | @@ -5434,7 +5434,7 @@ | |||
306 | 5434 | innobase_log_group_home_dir ? innobase_log_group_home_dir : mysql_data_home); | 5434 | innobase_log_group_home_dir ? innobase_log_group_home_dir : mysql_data_home); |
307 | 5435 | printf("innodb_log_files_in_group = %ld\n", innobase_log_files_in_group); | 5435 | printf("innodb_log_files_in_group = %ld\n", innobase_log_files_in_group); |
308 | 5436 | printf("innodb_log_file_size = %lld\n", innobase_log_file_size); | 5436 | printf("innodb_log_file_size = %lld\n", innobase_log_file_size); |
310 | 5437 | exit(0); | 5437 | exit(EXIT_SUCCESS); |
311 | 5438 | } | 5438 | } |
312 | 5439 | 5439 | ||
313 | 5440 | if (!xtrabackup_stream) { | 5440 | if (!xtrabackup_stream) { |
314 | @@ -5464,7 +5464,7 @@ | |||
315 | 5464 | if (xtrabackup_prepare) num++; | 5464 | if (xtrabackup_prepare) num++; |
316 | 5465 | if (num != 1) { /* !XOR (for now) */ | 5465 | if (num != 1) { /* !XOR (for now) */ |
317 | 5466 | usage(); | 5466 | usage(); |
319 | 5467 | exit(-1); | 5467 | exit(EXIT_FAILURE); |
320 | 5468 | } | 5468 | } |
321 | 5469 | } | 5469 | } |
322 | 5470 | 5470 | ||
323 | @@ -5516,5 +5516,5 @@ | |||
324 | 5516 | hash_table_free(tables_hash); | 5516 | hash_table_free(tables_hash); |
325 | 5517 | } | 5517 | } |
326 | 5518 | 5518 | ||
328 | 5519 | exit(0); | 5519 | exit(EXIT_SUCCESS); |
329 | 5520 | } | 5520 | } |
seem OK