mirror of
https://github.com/EnterpriseDB/repmgr.git
synced 2026-03-24 07:36:30 +00:00
Break out error codes, cleanup header files and HISTORY
This commit is contained in:
15
strutil.c
15
strutil.c
@@ -3,6 +3,19 @@
|
||||
*
|
||||
* Copyright (C) 2ndQuadrant, 2011
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#include <stdarg.h>
|
||||
@@ -24,7 +37,7 @@ xvsnprintf(char *str, size_t size, const char *format, va_list ap)
|
||||
if (retval >= size)
|
||||
{
|
||||
fprintf(stderr, "Buffer not large enough to format entire string\n");
|
||||
exit(255);
|
||||
exit(ERR_STR_OVERFLOW);
|
||||
}
|
||||
|
||||
return retval;
|
||||
|
||||
Reference in New Issue
Block a user