aboutsummaryrefslogtreecommitdiff
path: root/gprofng
diff options
context:
space:
mode:
authorVladimir Mezentsev <vladimir.mezentsev@oracle.com>2024-09-25 15:31:34 -0700
committerVladimir Mezentsev <vladimir.mezentsev@oracle.com>2024-09-26 11:33:29 -0700
commit519aef2dae56a3b71016ed3a39929f59e3a0955a (patch)
treec434e8bef72e70727b1c453a8887b2a32a4310c9 /gprofng
parent039db5946f74eb35c4f4ad8c79914ced9a8c0810 (diff)
downloadbinutils-519aef2dae56a3b71016ed3a39929f59e3a0955a.zip
binutils-519aef2dae56a3b71016ed3a39929f59e3a0955a.tar.gz
binutils-519aef2dae56a3b71016ed3a39929f59e3a0955a.tar.bz2
Fix 32207 [gprofng collect app] Error in parsing the -O option
gprofng/ChangeLog 2024-09-25 Vladimir Mezentsev <vladimir.mezentsev@oracle.com> PR 32207 * src/collctrl.cc (preprocess_names): Fix the size in strndup.
Diffstat (limited to 'gprofng')
-rw-r--r--gprofng/src/collctrl.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/gprofng/src/collctrl.cc b/gprofng/src/collctrl.cc
index d341cb0..2fa9a88 100644
--- a/gprofng/src/collctrl.cc
+++ b/gprofng/src/collctrl.cc
@@ -2422,7 +2422,7 @@ Coll_Ctrl::preprocess_names ()
}
else
{
- expt_dir = dbe_strndup (expt_name, s - expt_name - 1);
+ expt_dir = dbe_strndup (expt_name, s - expt_name);
base_name = strdup (s + 1);
}