diff options
author | mrg <mrg@pkgsrc.org> | 2004-07-15 13:27:48 +0000 |
---|---|---|
committer | mrg <mrg@pkgsrc.org> | 2004-07-15 13:27:48 +0000 |
commit | 7e21400c94d98b27305a3bc2276af9f34abe8e37 (patch) | |
tree | b781c2f6e363d48748b0b5da84ffc021cf5ce2f9 /misc/udfclient | |
parent | fc250c5bd6d52f5579acb338907b0b6566afe2c2 (diff) | |
download | pkgsrc-7e21400c94d98b27305a3bc2276af9f34abe8e37.tar.gz |
- fix printing file sizes >= 2GB
- add "exit" support
Diffstat (limited to 'misc/udfclient')
-rw-r--r-- | misc/udfclient/distinfo | 3 | ||||
-rw-r--r-- | misc/udfclient/patches/patch-aa | 36 |
2 files changed, 38 insertions, 1 deletions
diff --git a/misc/udfclient/distinfo b/misc/udfclient/distinfo index acc96e3e213..9695d4251cc 100644 --- a/misc/udfclient/distinfo +++ b/misc/udfclient/distinfo @@ -1,4 +1,5 @@ -$NetBSD: distinfo,v 1.7 2004/02/23 00:44:36 reinoud Exp $ +$NetBSD: distinfo,v 1.8 2004/07/15 13:27:48 mrg Exp $ SHA1 (UDFclient.0.2.tgz) = f857c3193d138e62452afde13ab88bee3a750a54 Size (UDFclient.0.2.tgz) = 78629 bytes +SHA1 (patch-aa) = b445a8e771879cb64f9301f2f89c2297049da8dc diff --git a/misc/udfclient/patches/patch-aa b/misc/udfclient/patches/patch-aa new file mode 100644 index 00000000000..e390a4d2d76 --- /dev/null +++ b/misc/udfclient/patches/patch-aa @@ -0,0 +1,36 @@ +$NetBSD: patch-aa,v 1.5 2004/07/15 13:27:48 mrg Exp $ + +- fix print when file sizes >= 2GB +- add "exit" and "^D" support + +--- udfclient.c.orig 2004-02-23 11:10:49.000000000 +1100 ++++ udfclient.c 2004-07-05 19:33:11.000000000 +1000 +@@ -520,7 +520,7 @@ void udfclient_getsubtree(struct udf_mou + } else { + printf("\r...%-47s ", name+strlen(name)-47); + }; +- printf("%10d / %10d bytes ", (uint32_t) data_pos, (uint32_t) file_data_total_len); ++ printf("%10llu / %10llu bytes ", (unsigned long long) data_pos, (unsigned long long) file_data_total_len); + if (file_data_total_len) printf("(%3d%%) ", (int) (100.0*(float) data_pos / file_data_total_len)); + printf("successfully"); + fflush(stdout); +@@ -575,6 +575,9 @@ void udfclient_interact(void) { + *line = 0; + fgets(line, 4096, stdin); + ++ if (*line == 0 && feof(stdin)) ++ return; ++ + *cmd = *arg1 = *arg2 = *arg3 = 0; + args = sscanf(line, "%s %s %s %s", cmd, arg1, arg2, arg3); + if (args) { +@@ -611,7 +614,8 @@ void udfclient_interact(void) { + ); + continue; + }; +- if (strcmp(cmd, "quit")==0) { ++ if (strcmp(cmd, "quit")==0 || ++ strcmp(cmd, "exit")==0) { + return; + }; + printf("\nUnknown command %s\n", cmd); |