projects
/
claws.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Remove unchecked realloc which is unnecessary
[claws.git]
/
src
/
plugins
/
archive
/
archiver_gtk.c
diff --git
a/src/plugins/archive/archiver_gtk.c
b/src/plugins/archive/archiver_gtk.c
index 447de796d12725023de9d6738a8215f026d2fa78..f42181dd4b23e7d4559f7a30b65af86522ceeeff 100644
(file)
--- a/
src/plugins/archive/archiver_gtk.c
+++ b/
src/plugins/archive/archiver_gtk.c
@@
-347,10
+347,8
@@
static gchar* descriptive_file_name(
/* ensure file name is not larger than 96 chars (max file name size
* is 100 chars but reserve for .md5)
*/
- if (strlen(name) > 96) {
- name = realloc(name, 97);
+ if (strlen(name) > 96)
name[96] = 0;
- }
new_file = g_strconcat(p, "/", name, NULL);