From 2eea744e656d5705be2b4d610dbf7f3a8ae79928 Mon Sep 17 00:00:00 2001 From: Ricardo Mones Date: Tue, 20 Sep 2016 19:27:26 +0200 Subject: [PATCH] Remove unused function --- src/common/utils.c | 28 +--------------------------- src/common/utils.h | 5 +---- 2 files changed, 2 insertions(+), 31 deletions(-) diff --git a/src/common/utils.c b/src/common/utils.c index b8727e413..053a0b04f 100644 --- a/src/common/utils.c +++ b/src/common/utils.c @@ -1,6 +1,6 @@ /* * Claws Mail -- a GTK+ based, lightweight, and fast e-mail client - * Copyright (C) 1999-2015 Hiroyuki Yamamoto & The Claws Mail Team + * Copyright (C) 1999-2016 Hiroyuki Yamamoto & The Claws Mail Team * * 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 @@ -2055,32 +2055,6 @@ time_t get_file_mtime(const gchar *file) return s.st_mtime; } -off_t get_file_size_as_crlf(const gchar *file) -{ - FILE *fp; - off_t size = 0; - gchar buf[BUFFSIZE]; - - if ((fp = g_fopen(file, "rb")) == NULL) { - FILE_OP_ERROR(file, "g_fopen"); - return -1; - } - - while (fgets(buf, sizeof(buf), fp) != NULL) { - strretchomp(buf); - size += strlen(buf) + 2; - } - - if (ferror(fp)) { - FILE_OP_ERROR(file, "fgets"); - size = -1; - } - - fclose(fp); - - return size; -} - gboolean file_exist(const gchar *file, gboolean allow_fifo) { GStatBuf s; diff --git a/src/common/utils.h b/src/common/utils.h index e07fdd8ea..90f255a6e 100644 --- a/src/common/utils.h +++ b/src/common/utils.h @@ -1,6 +1,6 @@ /* * Claws Mail -- a GTK+ based, lightweight, and fast e-mail client - * Copyright (C) 1999-2014 Hiroyuki Yamamoto and the Claws Mail team + * Copyright (C) 1999-2016 Hiroyuki Yamamoto and the Claws Mail team * * 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 @@ -18,7 +18,6 @@ * The code of the g_utf8_substring function below is owned by * Matthias Clasen / * and is got from GLIB 2.30 - * */ #ifndef __UTILS_H__ @@ -432,8 +431,6 @@ const gchar *w32_get_cert_file (void); #endif /* file / directory handling */ off_t get_file_size (const gchar *file); -off_t get_file_size_as_crlf (const gchar *file); - time_t get_file_mtime (const gchar *file); gboolean file_exist (const gchar *file, -- 2.25.1