Skip to contentSkip to conversation

rt_tgsigqueueinfo01.c: replace definition ANDROID with __ANDROID__

PATCH New Zhengwang Ruan 3 participants 5 messages Apr 11, 2019 – Apr 14, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 rt_tgsigqueueinfo01.c: replace definition ANDROID with __ANDROID__

Replace the incorrect definition of ANDROID with __ANDROID__.

---
 testcases/kernel/syscalls/rt_tgsigqueueinfo/rt_tgsigqueueinfo01.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
testcases/kernel/syscalls/rt_tgsigqueueinfo/rt_tgsigqueueinfo01.c +1 -1
index c8252ed..bee6a62 100644
@@ -25,7 +25,7 @@
 #include "tst_test.h"
 #include "lapi/syscalls.h"
 
-#ifndef ANDROID
+#ifndef __ANDROID__
 #define SI_SIGVAL si_sigval
 #else
 #define SI_SIGVAL _sigval
Signature · 1 line
2.7.4
#1 lore raw

PATCH 1/1 rt_tgsigqueueinfo01.c: replace definition ANDROID with __ANDROID__

Hi,

testcases/kernel/syscalls/rt_tgsigqueueinfo/rt_tgsigqueueinfo01.c line 28

Quoted 9 lines

Replace the incorrect definition of ANDROID with __ANDROID__.

+++ b/testcases/kernel/syscalls/rt_tgsigqueueinfo/rt_tgsigqueueinfo01.c

testcases/kernel/syscalls/rt_tgsigqueueinfo/rt_tgsigqueueinfo01.c +1 -1
@@ -25,7 +25,7 @@
 #include "tst_test.h"
 #include "lapi/syscalls.h"
 
-#ifndef ANDROID
+#ifndef __ANDROID__

Simple grep in AOSP tree would be for this change (and I'd personally prefer it as well) I'd kindly ask android devs which one is correct :). BTW ANDROID was added by Steve.

$ cgrep '#if.* __ANDROID__' |wc -l
405
$ cgrep '#if.* ANDROID[^_]' |wc -l
22

Kind regards,
Petr

author
#2 lore raw

PATCH 1/1 rt_tgsigqueueinfo01.c: replace definition ANDROID with __ANDROID__

Hi Petr, Sandeep, Steve,

-------- Original Message --------
From: Petr Vorel
Sent: Thu, 11 Apr 2019 19:46:38 +0200
To: Zhengwang Ruan, Steve Muckle, Sandeep Patil
Cc: Ltp
Subject: Re: [LTP] [PATCH v1] rt_tgsigqueueinfo01.c: replace definition ANDROID with __ANDROID__

Quoted 11 lines

Hi,

testcases/kernel/syscalls/rt_tgsigqueueinfo/rt_tgsigqueueinfo01.c line 27

Quoted 7 lines

Replace the incorrect definition of ANDROID with __ANDROID__. +++ b/testcases/kernel/syscalls/rt_tgsigqueueinfo/rt_tgsigqueueinfo01.c

testcases/kernel/syscalls/rt_tgsigqueueinfo/rt_tgsigqueueinfo01.c +1 -1
@@ -25,7 +25,7 @@
  #include "tst_test.h"
  #include "lapi/syscalls.h"
-#ifndef ANDROID
+#ifndef __ANDROID__

Simple grep in AOSP tree would be for this change (and I'd personally prefer it as well) I'd kindly ask android devs which one is correct :). BTW ANDROID was added by Steve.

According to also [1], this patch is acceptable, right?

Quoted 9 lines
$ cgrep '#if.* __ANDROID__' |wc -l
405
$ cgrep '#if.* ANDROID[^_]' |wc -l
22

Kind regards,
Petr

Regards,

Zhengwang

[1] https://groups.google.com/forum/#!topic/android-ndk/cf9_f1SLXls

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linux.it/pipermail/ltp/attachments/20190412/9d22423b/attachment.html>

#3 lore raw

PATCH 1/1 rt_tgsigqueueinfo01.c: replace definition ANDROID with __ANDROID__

Quoted 22 lines · 阮正旺

Hi Petr, Sandeep, Steve,

-------- Original Message --------
From: Petr Vorel
Sent: Thu, 11 Apr 2019 19:46:38 +0200
To: Zhengwang Ruan, Steve Muckle, Sandeep Patil
Cc: Ltp
Subject: Re: [LTP] [PATCH v1] rt_tgsigqueueinfo01.c: replace definition ANDROID with __ANDROID__

Quoted 11 lines

Hi,

testcases/kernel/syscalls/rt_tgsigqueueinfo/rt_tgsigqueueinfo01.c line 27

Quoted 7 lines

Replace the incorrect definition of ANDROID with __ANDROID__. +++ b/testcases/kernel/syscalls/rt_tgsigqueueinfo/rt_tgsigqueueinfo01.c

testcases/kernel/syscalls/rt_tgsigqueueinfo/rt_tgsigqueueinfo01.c +1 -1
@@ -25,7 +25,7 @@
  #include "tst_test.h"
  #include "lapi/syscalls.h"
-#ifndef ANDROID
+#ifndef __ANDROID__

Simple grep in AOSP tree would be for this change (and I'd personally prefer it as well) I'd kindly ask android devs which one is correct :). BTW ANDROID was added by Steve.

Quoted 1 line

According to also [1], this patch is acceptable, right?

Yes, indeed.

#4 lore raw

PATCH 1/1 rt_tgsigqueueinfo01.c: replace definition ANDROID with __ANDROID__

Hi Sandeep, Zhengwang,

Quoted 23 lines · 阮正旺
Quoted 21 lines

Hi Petr, Sandeep, Steve,

-------- Original Message --------
From: Petr Vorel
Sent: Thu, 11 Apr 2019 19:46:38 +0200
To: Zhengwang Ruan, Steve Muckle, Sandeep Patil
Cc: Ltp
Subject: Re: [LTP] [PATCH v1] rt_tgsigqueueinfo01.c: replace definition ANDROID with __ANDROID__

Quoted 11 lines

Hi,

testcases/kernel/syscalls/rt_tgsigqueueinfo/rt_tgsigqueueinfo01.c line 27

Quoted 7 lines

Replace the incorrect definition of ANDROID with __ANDROID__. +++ b/testcases/kernel/syscalls/rt_tgsigqueueinfo/rt_tgsigqueueinfo01.c

testcases/kernel/syscalls/rt_tgsigqueueinfo/rt_tgsigqueueinfo01.c +1 -1
@@ -25,7 +25,7 @@
  #include "tst_test.h"
  #include "lapi/syscalls.h"
-#ifndef ANDROID
+#ifndef __ANDROID__

Simple grep in AOSP tree would be for this change (and I'd personally prefer it as well) I'd kindly ask android devs which one is correct :). BTW ANDROID was added by Steve.

Quoted 5 lines
Quoted 1 line

According to also [1], this patch is acceptable, right?

Yes, indeed.

Thanks for your review.
Merged (with slightly changed commit message) + I made this change in include/tst_safe_posix_ipc.h in a separate commit.

Kind regards,
Petr