summaryrefslogtreecommitdiff
path: root/src/general.c
diff options
context:
space:
mode:
authorIngo Bürk <admin@airblader.de>2018-06-22 13:55:09 +0200
committerGitHub <noreply@github.com>2018-06-22 13:55:09 +0200
commit4d3344ab9cd68bad5faf4ed3dad185dfcacb1e3d (patch)
tree66846b5f6023291fda2d72fe523d4ee0614d2a1f /src/general.c
parent64fd6e10478cabd0e2f9b554b71971a865c02d60 (diff)
parentc221b4d331d46d07fe24afc78e4eeb021556d013 (diff)
Merge pull request #290 from duskCoder/changes
Fix potential issues & avoid unnecessary instructions
Diffstat (limited to 'src/general.c')
-rw-r--r--src/general.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/general.c b/src/general.c
index f299a2b..2424cc6 100644
--- a/src/general.c
+++ b/src/general.c
@@ -51,12 +51,10 @@ char *skip_character(char *input, char character, int amount) {
*
*/
void die(const char *fmt, ...) {
- char buffer[512];
va_list ap;
va_start(ap, fmt);
- (void)vsnprintf(buffer, sizeof(buffer), fmt, ap);
+ (void)vfprintf(stderr, fmt, ap);
va_end(ap);
- fprintf(stderr, "%s", buffer);
exit(EXIT_FAILURE);
}