Skip to content

Commit 40a95aa

Browse files
committed
Use unsigned into for slock_t for pre-sparcv8plus.
1 parent eed57b1 commit 40a95aa

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/include/storage/s_lock.h

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@
6666
* Portions Copyright (c) 1996-2006, PostgreSQL Global Development Group
6767
* Portions Copyright (c) 1994, Regents of the University of California
6868
*
69-
* $PostgreSQL: pgsql/src/include/storage/s_lock.h,v 1.154 2006/05/18 16:02:30 momjian Exp $
69+
* $PostgreSQL: pgsql/src/include/storage/s_lock.h,v 1.155 2006/05/18 21:18:40 momjian Exp $
7070
*
7171
*-------------------------------------------------------------------------
7272
*/
@@ -770,7 +770,12 @@ typedef unsigned char slock_t;
770770

771771
#if defined(__sun) && (defined(__i386) || defined(__x86_64__) || defined(__sparc__) || defined(__sparc))
772772
#define HAS_TEST_AND_SET
773+
774+
#if defined(__sparcv9) || defined(__sparcv8plus)
773775
typedef unsigned int slock_t;
776+
#else
777+
typedef unsigned char slock_t;
778+
#endif
774779

775780
extern slock_t pg_atomic_cas(volatile slock_t *lock, slock_t with,
776781
slock_t cmp);

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy