summaryrefslogtreecommitdiffstats
path: root/rosicchio.c
diff options
context:
space:
mode:
Diffstat (limited to 'rosicchio.c')
-rw-r--r--rosicchio.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/rosicchio.c b/rosicchio.c
index 53f714e..ffd3ee8 100644
--- a/rosicchio.c
+++ b/rosicchio.c
@@ -26,7 +26,7 @@ int main(int argc, char* argv[]) {
/* The truncate function "rosicchia" la parte di chiave utilizzata */
- truncate(argv[2], (pad_size - mess_size));
+ ftruncate(fileno(pad), (pad_size - mess_size));
fseek(pad, 0L, SEEK_END);
long new_pad_size = ftell(pad);