summaryrefslogtreecommitdiff
path: root/net-dialup/xc/files/xc-4.3.2-fix-set_bps-overflow.patch
diff options
context:
space:
mode:
Diffstat (limited to 'net-dialup/xc/files/xc-4.3.2-fix-set_bps-overflow.patch')
-rw-r--r--net-dialup/xc/files/xc-4.3.2-fix-set_bps-overflow.patch14
1 files changed, 14 insertions, 0 deletions
diff --git a/net-dialup/xc/files/xc-4.3.2-fix-set_bps-overflow.patch b/net-dialup/xc/files/xc-4.3.2-fix-set_bps-overflow.patch
new file mode 100644
index 000000000000..5934aa2f6d77
--- /dev/null
+++ b/net-dialup/xc/files/xc-4.3.2-fix-set_bps-overflow.patch
@@ -0,0 +1,14 @@
+diff -Naurp xc-4.3.2.orig/xcmain.c xc-4.3.2/xcmain.c
+--- xc-4.3.2.orig/xcmain.c 1996-11-24 01:35:41.000000000 -0500
++++ xc-4.3.2/xcmain.c 2014-04-18 19:58:26.267227496 -0400
+@@ -696,8 +696,8 @@ static void
+ SET_bps()
+ {
+ if (statflag){
+- char br[6];
+- sprintf(br, "%d", mrate( NULL ));
++ char br[11];
++ snprintf(br, 11, "%d", mrate( NULL ));
+ fprintf(tfp, statfmt, "bps", "Bits per Second", br);
+ return;
+ }