linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] fix build
@ 2011-10-17 10:56 Frédéric Danis
  2011-10-17 11:10 ` Johan Hedberg
  0 siblings, 1 reply; 5+ messages in thread
From: Frédéric Danis @ 2011-10-17 10:56 UTC (permalink / raw)
  To: linux-bluetooth

src/eir.c: In function ‘eir_parse’:
src/eir.c:72: error: ‘name_len’ may be used uninitialized in this function

and

thermometer/thermometer.c: In function ‘destroy_char’:
thermometer/thermometer.c:79: error: implicit declaration of function ‘g_slist_free_full’
---
 src/eir.c                 |    2 +-
 thermometer/thermometer.c |    5 +++++
 2 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/src/eir.c b/src/eir.c
index 8772191..8ada364 100644
--- a/src/eir.c
+++ b/src/eir.c
@@ -69,7 +69,7 @@ int eir_parse(struct eir_data *eir, uint8_t *eir_data)
 	uuid_t service;
 	char *uuid_str;
 	const char *name = NULL;
-	size_t name_len;
+	size_t name_len = 0;
 	unsigned int i;
 
 	eir->flags = -1;
diff --git a/thermometer/thermometer.c b/thermometer/thermometer.c
index 7621926..653ec76 100644
--- a/thermometer/thermometer.c
+++ b/thermometer/thermometer.c
@@ -20,6 +20,10 @@
  *
  */
 
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
 #include <gdbus.h>
 #include <errno.h>
 #include <bluetooth/uuid.h>
@@ -34,6 +38,7 @@
 #include "att.h"
 #include "gatt.h"
 #include "thermometer.h"
+#include "glib-helper.h"
 
 #define THERMOMETER_INTERFACE "org.bluez.Thermometer"
 
-- 
1.7.1


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

* Re: [PATCH] fix build
  2011-10-17 10:56 [PATCH] fix build Frédéric Danis
@ 2011-10-17 11:10 ` Johan Hedberg
  2011-10-17 11:16   ` Johan Hedberg
  2011-10-17 13:03   ` Frederic Danis
  0 siblings, 2 replies; 5+ messages in thread
From: Johan Hedberg @ 2011-10-17 11:10 UTC (permalink / raw)
  To: Frédéric Danis; +Cc: linux-bluetooth

Hi Frédéric,

On Mon, Oct 17, 2011, Frédéric Danis wrote:
> src/eir.c: In function ‘eir_parse’:
> src/eir.c:72: error: ‘name_len’ may be used uninitialized in this function
> 
> and
> 
> thermometer/thermometer.c: In function ‘destroy_char’:
> thermometer/thermometer.c:79: error: implicit declaration of function ‘g_slist_free_full’
> ---
>  src/eir.c                 |    2 +-
>  thermometer/thermometer.c |    5 +++++
>  2 files changed, 6 insertions(+), 1 deletions(-)

Strange. Current git compiles just fine under Fedora 16 beta (gcc 2.6.1)
as well as debian unstable (also gcc 2.6.1). Which gcc version do you
use?

I'd push the patch upstream but it fails to apply:

	fatal: cannot convert from UTF-8utf-8 to UTF-8

I suspect that's because of the double Content-Type header in your
email. Could you try to fix it?

Johan

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

* Re: [PATCH] fix build
  2011-10-17 11:10 ` Johan Hedberg
@ 2011-10-17 11:16   ` Johan Hedberg
  2011-10-17 13:03   ` Frederic Danis
  1 sibling, 0 replies; 5+ messages in thread
From: Johan Hedberg @ 2011-10-17 11:16 UTC (permalink / raw)
  To: Frédéric Danis, linux-bluetooth

On Mon, Oct 17, 2011, Johan Hedberg wrote:
> Strange. Current git compiles just fine under Fedora 16 beta (gcc 2.6.1)
> as well as debian unstable (also gcc 2.6.1). Which gcc version do you
> use?

s/2.6.1/4.6.1/

Johan

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

* Re: [PATCH] fix build
  2011-10-17 11:10 ` Johan Hedberg
  2011-10-17 11:16   ` Johan Hedberg
@ 2011-10-17 13:03   ` Frederic Danis
  2011-10-17 15:59     ` Frederic Danis
  1 sibling, 1 reply; 5+ messages in thread
From: Frederic Danis @ 2011-10-17 13:03 UTC (permalink / raw)
  To: linux-bluetooth

Hello Johan,

Le 17/10/2011 13:10, Johan Hedberg a écrit :
> Hi Frédéric,
>
> On Mon, Oct 17, 2011, Frédéric Danis wrote:
>> src/eir.c: In function ‘eir_parse’:
>> src/eir.c:72: error: ‘name_len’ may be used uninitialized in this function
>>
>> and
>>
>> thermometer/thermometer.c: In function ‘destroy_char’:
>> thermometer/thermometer.c:79: error: implicit declaration of function ‘g_slist_free_full’
>> ---
>>   src/eir.c                 |    2 +-
>>   thermometer/thermometer.c |    5 +++++
>>   2 files changed, 6 insertions(+), 1 deletions(-)
>
> Strange. Current git compiles just fine under Fedora 16 beta (gcc 2.6.1)
> as well as debian unstable (also gcc 2.6.1). Which gcc version do you
> use?

Ubuntu 10.10 32 bits with gcc version 4.4.5 (Ubuntu/Linaro 4.4.4-14ubuntu5)
>
> I'd push the patch upstream but it fails to apply:
>
> 	fatal: cannot convert from UTF-8utf-8 to UTF-8
>
> I suspect that's because of the double Content-Type header in your
> email. Could you try to fix it?

I will send new version removing double Content-Type header

Fred

-- 
Frederic Danis                            Open Source Technology Centre
frederic.danis@intel.com                              Intel Corporation


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

* Re: [PATCH] fix build
  2011-10-17 13:03   ` Frederic Danis
@ 2011-10-17 15:59     ` Frederic Danis
  0 siblings, 0 replies; 5+ messages in thread
From: Frederic Danis @ 2011-10-17 15:59 UTC (permalink / raw)
  To: linux-bluetooth

Hello Johan,

>>
>> I'd push the patch upstream but it fails to apply:
>>
>> fatal: cannot convert from UTF-8utf-8 to UTF-8
>>
>> I suspect that's because of the double Content-Type header in your
>> email. Could you try to fix it?
>
> I will send new version removing double Content-Type header

I finally found that ‘ generates this behavior, replacing it by ' remove 
the "cannot convert from UTF-8utf-8" problem.

Sent a v3 patch.

Fred

-- 
Frederic Danis                            Open Source Technology Centre
frederic.danis@intel.com                              Intel Corporation


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

end of thread, other threads:[~2011-10-17 15:59 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-10-17 10:56 [PATCH] fix build Frédéric Danis
2011-10-17 11:10 ` Johan Hedberg
2011-10-17 11:16   ` Johan Hedberg
2011-10-17 13:03   ` Frederic Danis
2011-10-17 15:59     ` Frederic Danis

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).