summaryrefslogtreecommitdiff
path: root/x11-misc/virtualgl/files/virtualgl-3.1-drop-register.patch
blob: 5e7153c3c3831120f755631097e3e4d44559d1d9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
https://github.com/VirtualGL/virtualgl/pull/233
From: Brahmajit Das <brahmajit.xyz@gmail.com>
Date: Thu, 1 Jun 2023 14:45:17 +0530
Subject: [PATCH] Dropping use of register keyword

The usage of register keyword was deprecated in c++14 and it's
completely removed in c++17. Found will building virtualgl on gentoo
with clang-16.

Bug: https://bugs.gentoo.org/898876
Signed-off-by: Brahmajit Das <brahmajit.xyz@gmail.com>
--- a/server/fltk/src/Fl_Text_Buffer.cxx
+++ b/server/fltk/src/Fl_Text_Buffer.cxx
@@ -1286,7 +1286,7 @@ int Fl_Text_Buffer::substitute_null_characters( char *string, int len ) {
 ** routine if no substitution has been done.
 */
 void Fl_Text_Buffer::unsubstitute_null_characters( char *string ) {
-  register char * c, subsChar = mNullSubsChar;
+  char * c, subsChar = mNullSubsChar;
 
   if ( subsChar == '\0' )
     return;
--- a/server/fltk/src/Fl_arg.cxx
+++ b/server/fltk/src/Fl_arg.cxx
@@ -314,7 +314,7 @@ without express or implied warranty.
 
 static int ReadInteger(char* string, char** NextString)
 {
-  register int Result = 0;
+  int Result = 0;
   int Sign = 1;
     
   if (*string == '+')
@@ -337,7 +337,7 @@ int XParseGeometry(const char* string, int* x, int* y,
 		   unsigned int* width, unsigned int* height)
 {
   int mask = NoValue;
-  register char *strind;
+  char *strind;
   unsigned int tempWidth = 0, tempHeight = 0;
   int tempX = 0, tempY = 0;
   char *nextCharacter;
--- a/util/md5.c
+++ b/util/md5.c
@@ -193,7 +193,7 @@ void MD5Final(unsigned char digest[16], struct MD5Context *ctx)
  */
 void MD5Transform(uint32 buf[4], uint32 in[16])
 {
-  register uint32 a, b, c, d;
+  uint32 a, b, c, d;
 
   a = buf[0];
   b = buf[1];