[Bug 905] New: Typo, signed/unsigned char Exim-4.70 CVS (2009-11-09 18:29:22 +0100)

View: New views
12 Messages — Rating Filter:   Alert me  

[Bug 905] New: Typo, signed/unsigned char Exim-4.70 CVS (2009-11-09 18:29:22 +0100)

by Bugzilla from serge-exim@srv0.ath.cx :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=905
           Summary: Typo, signed/unsigned char Exim-4.70 CVS (2009-11-09
                    18:29:22 +0100)
           Product: Exim
           Version: N/A
          Platform: All
        OS/Version: Linux
            Status: NEW
          Severity: bug
          Priority: medium
         Component: Packaging
        AssignedTo: nigel@...
        ReportedBy: serge-exim@...
                CC: exim-dev@...


Created an attachment (id=341)
 --> (http://bugs.exim.org/attachment.cgi?id=341)
exim-4.70-CVS.2009.11.09-differ_in_signedness.patch

* Typo, signed/unsigned char:

src/dns.c
src/dcc.c
src/malware.c
src/mime.c
src/receive.c
src/spf.c


* Unused variables in src/dcc.c: (this patch NOT remove variables)

src/dcc.c:96: warning: unused variable 'pollfd'
src/dcc.c:94: warning: unused variable 'server'
src/dcc.c:93: warning: unused variable 'start'
src/dcc.c:92: warning: unused variable 'override'
src/dcc.c:91: warning: unused variable 'q'
src/dcc.c:91: warning: unused variable 'p'
src/dcc.c:90: warning: unused variable 'offset'
src/dcc.c:85: warning: unused variable 'dcc_rcpt'
src/dcc.c:62: warning: unused variable 'dcc_request'
src/dcc.c:61: warning: unused variable 'dcc_daemon_port'
src/dcc.c:59: warning: unused variable 'dcc_buffer'
src/dcc.c:58: warning: unused variable 'dcc_sock'
src/dcc.c:56: warning: unused variable 'mbox_size'
src/dcc.c:55: warning: unused variable 'user_name_buffer'
src/dcc.c:54: warning: unused variable 'body_begin'
src/dcc.c:53: warning: unused variable 'user_name'


--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email

--
## List details at http://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##

[Bug 905] Typo, signed/unsigned char Exim-4.70 CVS (2009-11-09 18:29:22 +0100)

by Bugzilla from wbreyha@gmx.net :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=905

Wolfgang Breyha <wbreyha@...> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |wbreyha@...




--- Comment #1 from Wolfgang Breyha <wbreyha@...>  2009-11-10 13:08:19 ---
I fixed the rest of "-W all" warnings for dcc.c. patch attached. patch is
against >exim-4.70-CVS.2009.11.09-differ_in_signedness.patch< !


--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email

--
## List details at http://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##

[Bug 905] Typo, signed/unsigned char Exim-4.70 CVS (2009-11-09 18:29:22 +0100)

by Bugzilla from wbreyha@gmx.net :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=905




--- Comment #2 from Wolfgang Breyha <wbreyha@...>  2009-11-10 13:09:34 ---
Created an attachment (id=342)
 --> (http://bugs.exim.org/attachment.cgi?id=342)
dcc.c fixes (unused variables, pointer fix)


--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email

--
## List details at http://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##

Re: [Bug 905] Typo, signed/unsigned char Exim-4.70 CVS (2009-11-09 18:29:22 +0100)

by S e r g e :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Le Tuesday 10 November 2009 14:09:34 Wolfgang Breyha, vous avez écrit :

> ------- You are receiving this mail because: -------
> You are on the CC list for the bug.
>
> http://bugs.exim.org/show_bug.cgi?id=905
>
>
>
>
> --- Comment #2 from Wolfgang Breyha <wbreyha@...>  2009-11-10 13:09:34
> --- Created an attachment (id=342)
>  --> (http://bugs.exim.org/attachment.cgi?id=342)
> dcc.c fixes (unused variables, pointer fix)
>
>
> --
> Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email

Hi,

with your last patch, it still remains:

312c312
<     debug_printf("\n****************************\n", sendbuf);
---
>     debug_printf("\n****************************\n%s", sendbuf);
363c363
<   while(resp = read(sockfd, recvbuf, sizeof(recvbuf)-1) > 0) {
---
>   while((resp = read(sockfd, recvbuf, sizeof(recvbuf)-1)) > 0) {
388c388
<               dcc_result = "A";
---
>               dcc_result = US"A";
394c394
<               dcc_result = "R";
---
>               dcc_result = US"R";
410c410
<               dcc_result = "A";
---
>               dcc_result = US"A";
417c417
<               dcc_result = "G";
---
>               dcc_result = US"G";
426c426
<               dcc_result = "T";
---
>               dcc_result = US"T";
434c434
<               dcc_result = "T";
---
>               dcc_result = US"T";
500c500
<     if (((xtra_hdrs = expand_string("$acl_m_dcc_add_header")) != NULL) &&
(xtra_hdrs[0] != '\0')) {
---
>     if (((xtra_hdrs = expand_string(US"$acl_m_dcc_add_header")) != NULL) &&
(xtra_hdrs[0] != '\0')) {


---------------------------------------
Regards
--Serge

--
## List details at http://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##

[Bug 905] Typo, signed/unsigned char Exim-4.70 CVS (2009-11-09 18:29:22 +0100)

by Bugzilla from nigel@exim.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=905




--- Comment #3 from Nigel Metheringham <nigel@...>  2009-11-11 10:08:03 ---
CVS commit by nm4:

Applied signed/unsigned fixes.  Need confirmation that this completely deals
with bug.  Related: bug#905

--- CVS commit summary ---
1.3   1.4   +12 -32  -  exim/exim-src/src/dcc.c
1.19  1.20  +1 -1    -  exim/exim-src/src/dns.c
1.17  1.18  +1 -1    -  exim/exim-src/src/malware.c
1.18  1.19  +2 -2    -  exim/exim-src/src/mime.c
1.50  1.51  +3 -2    -  exim/exim-src/src/receive.c
1.8   1.9   +5 -5    -  exim/exim-src/src/spf.c


--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email

--
## List details at http://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##

[Bug 905] Typo, signed/unsigned char Exim-4.70 CVS (2009-11-09 18:29:22 +0100)

by Bugzilla from serge-exim@srv0.ath.cx :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=905

Serge Demonchaux <serge-exim@...> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |serge-exim@...




--- Comment #4 from Serge Demonchaux <serge-exim@...>  2009-11-11 13:29:48 ---
Very good.

src/dns.c       ===> OK
src/dcc.c       ===> OK
src/malware.c   ===> OK
src/mime.c      ===> OK
src/receive.c   ===> OK
src/spf.c       ===> OK



I'm missed this 'src/lookups/spf.c'
========================
--- /caos.dev/usr/src/rpm/BUILD/exim-4.70CVS/src/lookups/spf.c.ORI 2009-11-11
12:00:26 +0100
+++ /caos.dev/usr/src/rpm/BUILD/exim-4.70CVS/src/lookups/spf.c     2009-11-11
12:00:17 +0100
@@ -59,11 +59,11 @@
     return FAIL;
   }

-  if (SPF_request_set_ipv4_str(spf_request, filename)) {
+  if (SPF_request_set_ipv4_str(spf_request, CS filename)) {
     *errmsg = string_sprintf("invalid IP address '%s'", filename);
     return FAIL;
   }
-  if (SPF_request_set_env_from(spf_request, keystring)) {
+  if (SPF_request_set_env_from(spf_request, CS keystring)) {
     *errmsg = string_sprintf("invalid envelope from address '%s'",
keystring);
     return FAIL;
   }
========================

With Linux i386 + GCC (-Wall), Exim is compiled well. On the x86_64
AMD , there are problems with 'off_t': (build-Linux-x86_64/config.h)

#ifndef OFF_T_FMT
#define OFF_T_FMT  "%lld"
#define LONGLONG_T long long int
#endif


[...]
appendfile.c:2641: warning: format '%lld' expects type 'long long int', but
argument 3 has type 'off_t'
[...]


by changing the definitions, i have no warnings

build-Linux-x86_64/config.h:

--- exim-4.70/build-Linux-x86_64/config.h.ORI    2009-11-11 14:24:47 +0100
+++ exim-4.70/build-Linux-x86_64/config.h        2009-11-11 14:25:54 +0100
@@ -7,12 +7,12 @@
 Do not edit it. Instead, edit Local/Makefile and rerun make. */

 #ifndef OFF_T_FMT
-#define OFF_T_FMT  "%lld"
+#define OFF_T_FMT  "%" PRIi64
 #define LONGLONG_T int64_t
 #endif

 #ifndef TIME_T_FMT
-#define TIME_T_FMT  "%lld"
+#define TIME_T_FMT  "%" PRIi64
 #undef  LONGLONG_T
 #define LONGLONG_T int64_t
 #endif



Regards,
--Serge


--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email

--
## List details at http://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##

[Bug 905] Typo, signed/unsigned char Exim-4.70 CVS (2009-11-09 18:29:22 +0100)

by Bugzilla from nigel@exim.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=905




--- Comment #5 from Nigel Metheringham <nigel@...>  2009-11-11 14:43:29 ---
CVS commit by nm4:

More signed/unsigned fixes.  Need confirmation that this completely deals with
bug.  Related: bug#905

--- CVS commit summary ---
1.2  1.3  +2 -2  -  exim/exim-src/src/lookups/spf.c


--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email

--
## List details at http://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##

[Bug 905] Typo, signed/unsigned char Exim-4.70 CVS (2009-11-09 18:29:22 +0100)

by Bugzilla from nigel@exim.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=905




--- Comment #6 from Nigel Metheringham <nigel@...>  2009-11-11 14:45:03 ---
We need to change those config.h changes to a Makefile or buildconfig.c
patch.


--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email

--
## List details at http://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##

[Bug 905] Typo, signed/unsigned char Exim-4.70 CVS (2009-11-09 18:29:22 +0100)

by Bugzilla from serge-exim@srv0.ath.cx :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=905




--- Comment #7 from Serge Demonchaux <serge-exim@...>  2009-11-11 15:14:14 ---
> More signed/unsigned fixes.  Need confirmation that this completely deals
> with bug.  Related: bug#905

src/dns.c         ===> OK
src/dcc.c         ===> OK
src/malware.c     ===> OK
src/mime.c        ===> OK
src/receive.c     ===> OK
src/spf.c         ===> OK
src/lookups/spf.c ===> OK



------- Comment  #6 From Nigel Metheringham 2009-11-11 14:45:03  
> We need to change those config.h changes to a Makefile or buildconfig.c
> patch.

...or to leave the choie to the packager? I would not be to answer.
Call the list about this ?


See more about 'off_t' with "-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE":
<http://lists.freebsd.org/pipermail/freebsd-arch/2005-December/004685.html>

In Linux x86 with "-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE":
$ uname -m == i686
sizeof(test_off_t) == 8

In Linux x86 withOUT "-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE":
$ uname -m == i686
sizeof(test_off_t) == 4

In Linux x86_64 with "-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE":
$ uname -m == x86_64
sizeof(test_off_t) == 8

=============start=====================
--- exim-4.70/src/buildconfig.c.ORI      2009-11-11 15:05:15 +0100
+++ exim-4.70/src/buildconfig.c  2009-11-11 15:05:33 +0100
@@ -147,8 +147,8 @@
 fprintf(new, "#ifndef OFF_T_FMT\n");
 if (sizeof(test_off_t) > 4)
   {
-  fprintf(new, "#define OFF_T_FMT  \"%%lld\"\n");
-  fprintf(new, "#define LONGLONG_T long long int\n");
+  fprintf(new, "#define OFF_T_FMT  \"%%\" PRIi64\n");
+  fprintf(new, "#define LONGLONG_T int64_t\n");
   }
 else
   {
@@ -165,9 +165,9 @@
 fprintf(new, "#ifndef TIME_T_FMT\n");
 if (sizeof(test_time_t) > 4)
   {
-  fprintf(new, "#define TIME_T_FMT  \"%%lld\"\n");
+  fprintf(new, "#define TIME_T_FMT  \"%%\" PRIi64\n");
   fprintf(new, "#undef  LONGLONG_T\n");
-  fprintf(new, "#define LONGLONG_T long long int\n");
+  fprintf(new, "#define LONGLONG_T int64_t\n");
   }
 else
   {
=============end=====================



Best regards,
--Serge


--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email

--
## List details at http://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##

[Bug 905] Typo, signed/unsigned char Exim-4.70 CVS (2009-11-09 18:29:22 +0100)

by Bugzilla from nigel@exim.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=905




--- Comment #8 from Nigel Metheringham <nigel@...>  2009-11-11 15:49:14 ---
I'm not willing to take the buildconfig.c changes unless we can ensure that
this will not break older (or non linux/bsd) systems.

Are there any 64 bit systems which have older C libraries?
I guess this is the case since I was using Alpha based systems more
than 15 years back...


--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email

--
## List details at http://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##

[Bug 905] Typo, signed/unsigned char Exim-4.70 CVS (2009-11-09 18:29:22 +0100)

by Bugzilla from serge-exim@srv0.ath.cx :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=905




--- Comment #9 from Serge Demonchaux <serge-exim@...>  2009-11-11 16:52:22 ---
---- Comment  #8 From Nigel Metheringham 2009-11-11 15:49:14   -------  
> I'm not willing to take the buildconfig.c changes unless we can ensure that
> this will not break older (or non linux/bsd) systems.
>
> Are there any 64 bit systems which have older C libraries?
> I guess this is the case since I was using Alpha based systems more
> than 15 years back...

I'm in complete agreement with you on this. We are only sure for the x86_64.

We are too close to the release to consider this change. The next time after
tests in CVS...

Now it is possible to inform in documentation of this option of compilation.


See: ISO C99: 7.8 Format conversion of integer types    <inttypes.h>
              /usr/include/inttypes.h

Regards,
--Serge


--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email

--
## List details at http://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##

[Bug 905] Typo, signed/unsigned char Exim-4.70 CVS (2009-11-09 18:29:22 +0100)

by Bugzilla from serge-exim@srv0.ath.cx :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=905

Serge Demonchaux <serge-exim@...> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED




--- Comment #10 from Serge Demonchaux <serge-exim@...>  2009-11-11 17:00:14 ---
 signed/unsigned char bug has been fixed


--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email

--
## List details at http://lists.exim.org/mailman/listinfo/exim-dev Exim details at http://www.exim.org/ ##