Jim Meyering wrote:
> Kovarththanan Rajaratnam wrote:
>> clang detected the following false positive:
>>
>> sort.c:906:11: warning: The left operand of '<' is a garbage value
>> if (pid < 0)
>> ~~~ ^
>>
>> src/sort.c: Add an ass
Pádraig Brady wrote:
> On 06/01/10 08:36, Kovarththanan Rajaratnam wrote:
>> clang detected the following false positive:
>>
>> sort.c:2946:3: warning: Pass-by-value argument in function call is
>> undefined
>>free (buf.buf);
>>^ ~~~
>>
ich
is non null. That is why I preferred the assert(). Is this assumption
incorrect?
--
Best regards,
Kovarththanan Rajaratnam
Signed-off-by: Kovarththanan Rajaratnam
---
src/sort.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/src/sort.c b/src/sort.c
index 039df13..ac5d29f 100644
--- a/src/sort.c
+++ b/src/sort.c
@@ -1730,7 +1730,7 @@ find_unit_order (const char *number, struct keyfield
is always set/valid.
Signed-off-by: Kovarththanan Rajaratnam
---
src/sort.c |2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/src/sort.c b/src/sort.c
index 9c25723..039df13 100644
--- a/src/sort.c
+++ b/src/sort.c
@@ -2874,6 +2874,8 @@ sort (char * const *files, size_t
; will always be set/is valid.
Signed-off-by: Kovarththanan Rajaratnam
---
src/sort.c |2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/src/sort.c b/src/sort.c
index 010930b..9c25723 100644
--- a/src/sort.c
+++ b/src/sort.c
@@ -874,6 +874,8 @@ pipe_fork (int pipefds[2], size_
o be non null.
Signed-off-by: Kovarththanan Rajaratnam
---
src/sort.c |1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/src/sort.c b/src/sort.c
index b50f6cd..010930b 100644
--- a/src/sort.c
+++ b/src/sort.c
@@ -2432,6 +2432,7 @@ mergefps (struct sortfile *files, size_t n
>From c65f5323d2c187e01e73c7a074382f77ff8ee708 Mon Sep 17 00:00:00 2001
From: Kovarththanan Rajaratnam
Date: Tue, 5 Jan 2010 20:24:02 +0100
Subject: [PATCH] src/sort.c: assert on temp.text before calling memcpy()
clang detected the following false positive:
sort.c:2292:7: warning: Null poin