trafficserver-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Igor Galić <i.ga...@brainsware.org>
Subject Re: git commit: fix a wrong CAS operation of ink_time_t variables on 64 bit system.
Date Sat, 21 Apr 2012 14:39:21 GMT

What better way is there to welcome a new committer than a
failing build ;)


----- Original Message -----
> Updated Branches:
>   refs/heads/master 11c11c8e6 -> f4acef88e
> 
> 
> fix a wrong CAS operation of ink_time_t variables on 64 bit system.
> 
> 
> Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo
> Commit:
> http://git-wip-us.apache.org/repos/asf/trafficserver/commit/f4acef88
> Tree:
> http://git-wip-us.apache.org/repos/asf/trafficserver/tree/f4acef88
> Diff:
> http://git-wip-us.apache.org/repos/asf/trafficserver/diff/f4acef88
> 
> Branch: refs/heads/master
> Commit: f4acef88e0d1918e0b76fe83f1a1c5a62dd54974
> Parents: 11c11c8
> Author: weijin <weijin@apache.org>
> Authored: Sat Apr 21 21:45:43 2012 +0800
> Committer: weijin <weijin@apache.org>
> Committed: Sat Apr 21 21:57:19 2012 +0800
> 
> ----------------------------------------------------------------------
>  CHANGES                    |    2 ++
>  proxy/http/HttpTransact.cc |    8 ++++++--
>  2 files changed, 8 insertions(+), 2 deletions(-)
> ----------------------------------------------------------------------
> 
> 
> http://git-wip-us.apache.org/repos/asf/trafficserver/blob/f4acef88/CHANGES
> ----------------------------------------------------------------------
> diff --git a/CHANGES b/CHANGES
> index fc5e71c..4fad773 100644
> --- a/CHANGES
> +++ b/CHANGES
> @@ -1,5 +1,7 @@
>                                                           -*- coding:
>                                                           utf-8 -*-
>  Changes with Apache Traffic Server 3.1.4
> +  *) [TS-1130] Wrong CAS operation on ink_time_t on 64 bit system.
> +
>    *) [TS-1127] Wrong returned value of incoming port address. This
>     API is deprecated, so I also fixed the regression tests
>     accordingly.
>     Authors: Yakov Kopel and Leif.
> 
> http://git-wip-us.apache.org/repos/asf/trafficserver/blob/f4acef88/proxy/http/HttpTransact.cc
> ----------------------------------------------------------------------
> diff --git a/proxy/http/HttpTransact.cc b/proxy/http/HttpTransact.cc
> index 7537206..9ea25e8 100644
> --- a/proxy/http/HttpTransact.cc
> +++ b/proxy/http/HttpTransact.cc
> @@ -8298,8 +8298,12 @@ ink_cluster_time(void)
>    old = global_time;
>  
>    while (local_time > global_time) {
> -    if (ink_atomic_cas((int32_t *) & global_time, *((int32_t *) &
> old), *((int32_t *) & local_time))) {
> -      break;
> +    if (sizeof(ink_time_t) == 4) {
> +      if (ink_atomic_cas((int32_t *) & global_time, *((int32_t *) &
> old), *((int32_t *) & local_time)))
> +        break;
> +    } else if (sizeof(ink_time_t) == 8) {
> +      if ((ink_atomic_cas64((int64_t *) & global_time), *((int64_t
> *) & old), *((int64_t *) & local_time)))
> +        break;
>      }
>      old = global_time;
>    }

from http://ci.apache.org/builders/tserver-fedora-trunk/builds/1046

  CXX    HttpTransact.o
../../lib/ts/ink_atomic.h: In function ‘time_t ink_cluster_time()’:
../../lib/ts/ink_atomic.h:153: error: too few arguments to function ‘int64_t ink_atomic_cas64(volatile
vint64*, int64_t, int64_t)’
HttpTransact.cc:8305: error: at this point in file
make[3]: *** [HttpTransact.o] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all-recursive] Error 1
make[3]: Leaving directory `/home/buildslave13/slave13/tserver-fedora-trunk/build/proxy/http'


-- 
Igor Galić

Tel: +43 (0) 664 886 22 883
Mail: i.galic@brainsware.org
URL: http://brainsware.org/
GPG: 6880 4155 74BD FD7C B515  2EA5 4B1D 9E08 A097 C9AE


Mime
View raw message