[njs] Removed dead store assignment after 1c729f765cfb.
Dmitry Volyntsev
xeioex at nginx.com
Tue Jul 7 12:25:32 UTC 2020
details: https://hg.nginx.org/njs/rev/63b43891bc51
branches:
changeset: 1457:63b43891bc51
user: Dmitry Volyntsev <xeioex at nginx.com>
date: Tue Jul 07 12:23:47 2020 +0000
description:
Removed dead store assignment after 1c729f765cfb.
Found by Clang static analyzer.
diffstat:
src/njs_string.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diffs (12 lines):
diff -r e88aef77c653 -r 63b43891bc51 src/njs_string.c
--- a/src/njs_string.c Tue Jul 07 12:23:46 2020 +0000
+++ b/src/njs_string.c Tue Jul 07 12:23:47 2020 +0000
@@ -3631,7 +3631,7 @@ njs_string_prototype_replace(njs_vm_t *v
r = njs_cpymem(r, string.start, p - string.start);
r = njs_cpymem(r, ret_string.start, ret_string.size);
- r = njs_cpymem(r, p + s.size, string.size - s.size - (p - string.start));
+ memcpy(r, p + s.size, string.size - s.size - (p - string.start));
return NJS_OK;
}
More information about the nginx-devel
mailing list