Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] tslib: fix use of open()
@ 2010-04-23  8:24 luca at lucaceresoli.net
  2010-04-23  9:01 ` Peter Korsgaard
  0 siblings, 1 reply; 2+ messages in thread
From: luca at lucaceresoli.net @ 2010-04-23  8:24 UTC (permalink / raw)
  To: buildroot

From: Luca Ceresoli <luca@lucaceresoli.net>

Fixes error: "open with O_CREAT in second argument needs 3 arguments".

Original patch: svn://svn.berlios.de/tslib/trunk/tslib r72.

Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net>
---
 ...b-1.0-open-with-O_CREAT-needs-3-arguments.patch |   25 ++++++++++++++++++++
 1 files changed, 25 insertions(+), 0 deletions(-)
 create mode 100644 package/tslib/tslib-1.0-open-with-O_CREAT-needs-3-arguments.patch

diff --git a/package/tslib/tslib-1.0-open-with-O_CREAT-needs-3-arguments.patch b/package/tslib/tslib-1.0-open-with-O_CREAT-needs-3-arguments.patch
new file mode 100644
index 0000000..92b33f8
--- /dev/null
+++ b/package/tslib/tslib-1.0-open-with-O_CREAT-needs-3-arguments.patch
@@ -0,0 +1,25 @@
+diff -ur a/tests/ts_calibrate.c b/tests/ts_calibrate.c
+--- a/tests/ts_calibrate.c	2010-04-22 17:36:33.000000000 +0200
++++ b/tests/ts_calibrate.c	2010-04-22 17:38:09.000000000 +0200
+@@ -21,6 +21,7 @@
+ #include <sys/ioctl.h>
+ #include <sys/mman.h>
+ #include <sys/time.h>
++#include <sys/stat.h>
+ #include <linux/kd.h>
+ #include <linux/vt.h>
+ #include <linux/fb.h>
+@@ -224,9 +225,11 @@
+ 		for (i = 0; i < 7; i++) printf("%d ", cal.a [i]);
+ 		printf("\n");
+ 		if ((calfile = getenv("TSLIB_CALIBFILE")) != NULL) {
+-			cal_fd = open (calfile, O_CREAT | O_RDWR);
++		  cal_fd = open (calfile, O_CREAT | O_RDWR,
++		                 S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH);
+ 		} else {
+-			cal_fd = open ("/etc/pointercal", O_CREAT | O_RDWR);
++			cal_fd = open ("/etc/pointercal", O_CREAT | O_RDWR,
++		                 S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH);
+ 		}
+ 		sprintf (cal_buffer,"%d %d %d %d %d %d %d",
+ 			 cal.a[1], cal.a[2], cal.a[0],
-- 
1.6.3.3

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [Buildroot] [PATCH] tslib: fix use of open()
  2010-04-23  8:24 [Buildroot] [PATCH] tslib: fix use of open() luca at lucaceresoli.net
@ 2010-04-23  9:01 ` Peter Korsgaard
  0 siblings, 0 replies; 2+ messages in thread
From: Peter Korsgaard @ 2010-04-23  9:01 UTC (permalink / raw)
  To: buildroot

>>>>> "luca" == luca  <luca@lucaceresoli.net> writes:

 luca> From: Luca Ceresoli <luca@lucaceresoli.net>
 luca> Fixes error: "open with O_CREAT in second argument needs 3 arguments".

 luca> Original patch: svn://svn.berlios.de/tslib/trunk/tslib r72.

Thanks, committed - I grabbed the original patch for commit message /
attribution though.

-- 
Bye, Peter Korsgaard

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-04-23  9:01 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-04-23  8:24 [Buildroot] [PATCH] tslib: fix use of open() luca at lucaceresoli.net
2010-04-23  9:01 ` Peter Korsgaard

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox