]> git.pld-linux.org Git - packages/BillardGL.git/commitdiff
- initial
authorBartłomiej Zimoń <cactus@pld-linux.org>
Sat, 26 Jan 2008 23:09:49 +0000 (23:09 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    BillardGL-config_buffer_overflows.patch -> 1.1
    BillardGL-depracted.patch -> 1.1
    BillardGL-starting-resolution.patch -> 1.1

BillardGL-config_buffer_overflows.patch [new file with mode: 0755]
BillardGL-depracted.patch [new file with mode: 0755]
BillardGL-starting-resolution.patch [new file with mode: 0755]

diff --git a/BillardGL-config_buffer_overflows.patch b/BillardGL-config_buffer_overflows.patch
new file mode 100755 (executable)
index 0000000..248cd5d
--- /dev/null
@@ -0,0 +1,38 @@
+diff -ruN billard-gl-1.75.orig/src/KommandoZeilenParameter.cpp billard-gl-1.75/src/KommandoZeilenParameter.cpp
+--- billard-gl-1.75.orig/src/KommandoZeilenParameter.cpp       2002-04-23 18:04:13.000000000 +0200
++++ billard-gl-1.75/src/KommandoZeilenParameter.cpp    2005-01-22 12:33:22.000000000 +0100
+@@ -8,8 +8,8 @@
+ void SchreibeKonfiguration(){\r
+   FILE *f;\r
+ #ifndef _WIN32\r
+-  char dateiname[40];\r
+-  sprintf(dateiname,"%s/.BillardGL.conf.v7",getenv("HOME"));\r
++  char dateiname[512];\r
++  snprintf(dateiname,sizeof(dateiname),"%s/.BillardGL.conf.v7",getenv("HOME"));\r
+   f=fopen(dateiname,"w+");\r
+ #endif\r
+ #ifdef _WIN32\r
+@@ -65,8 +65,8 @@
+ void LeseKonfiguration(){\r
+   FILE *f;\r
+ #ifndef _WIN32\r
+-  char dateiname[40];\r
+-  sprintf(dateiname,"%s/.BillardGL.conf.v7",getenv("HOME"));\r
++  char dateiname[512];\r
++  snprintf(dateiname,sizeof(dateiname),"%s/.BillardGL.conf.v7",getenv("HOME"));\r
+   f=fopen(dateiname,"r");\r
+ #endif\r
+ #ifdef _WIN32\r
+@@ -95,9 +95,9 @@
+     fscanf(f,"%i",&GrueneLampe);\r
+     fscanf(f,"%f",&EffektLautstaerke);\r
+     fscanf(f,"%f",&MusikLautstaerke);\r
+-    fscanf(f,"%s",Spieler1temp);\r
+-    fscanf(f,"%s",Spieler2temp);\r
+-    fscanf(f,"%s",NetzwerkSpielertemp);\r
++    fscanf(f,"%9s",Spieler1temp);\r
++    fscanf(f,"%9s",Spieler2temp);\r
++    fscanf(f,"%9s",NetzwerkSpielertemp);\r
+     for (int i=0;i<10;i++) {\r
+       if (Spieler1temp[i]=='%') {\r
+       Spieler1[i]=' ';\r
diff --git a/BillardGL-depracted.patch b/BillardGL-depracted.patch
new file mode 100755 (executable)
index 0000000..3bb3359
--- /dev/null
@@ -0,0 +1,46 @@
+diff -ruN billard-gl-1.75.orig/src/BillardGL.cpp billard-gl-1.75/src/BillardGL.cpp
+--- billard-gl-1.75.orig/src/BillardGL.cpp     2002-04-23 18:17:42.000000000 +0200
++++ billard-gl-1.75/src/BillardGL.cpp  2005-01-23 03:50:58.000000000 +0100
+@@ -35,8 +35,6 @@
\r
+ #include "BillardGL.h"\r
\r
+-#pragma comment(linker, "/subsystem:\"windows\" /entry:\"mainCRTStartup\"")\r
+-\r
+ //Tabellen\r
+ GLfloat Bewegungstabelle[2000][16][3];\r
+ GLint   Soundtabelle[1000];\r
+diff -ruN billard-gl-1.75.orig/src/bmp.cpp billard-gl-1.75/src/bmp.cpp
+--- billard-gl-1.75.orig/src/bmp.cpp   2002-04-22 12:31:24.000000000 +0200
++++ billard-gl-1.75/src/bmp.cpp        2005-01-23 03:50:43.000000000 +0100
+@@ -4,14 +4,16 @@
+ // Modified by Volker Blanz, 25.4.2001\r
+ //\r
\r
+-#include <iostream.h>\r
+-#include <fstream.h>\r
++#include <iostream>\r
++#include <fstream>\r
+ #include <stdio.h>\r
+ #include <string.h>\r
+ #include "LA.h"\r
+ #include "Namen.h"\r
+ #include "bmp.h"\r
\r
++using namespace std;\r
++\r
+ // from ioutil:\r
\r
+ WORDX readWord(FILE *f) {\r
+diff -ruN billard-gl-1.75.orig/src/Kugel.cpp billard-gl-1.75/src/Kugel.cpp
+--- billard-gl-1.75.orig/src/Kugel.cpp 2002-04-22 12:58:08.000000000 +0200
++++ billard-gl-1.75/src/Kugel.cpp      2005-01-31 04:03:54.000000000 +0100
+@@ -123,7 +123,7 @@
+         glBindTexture(GL_TEXTURE_2D,Texturen[TG]);\r
+       sprintf(Name,"Texturen/%i/%i.bmp",TG,Nr); \r
+       loadBMP(tex_r,tex_g,tex_b,Name);\r
+-      GLfloat *texcoord;\r
++      GLfloat *texcoord = NULL;\r
+       if (tex_r.nrh!=tex_r.nch) {\r
+         GLfloat Aspekt=(tex_r.nch+1.0)/(tex_r.nrh+1.0);\r
+         texcoord = (GLfloat*) malloc (20*(Aufloesung+1)*(Aufloesung+2)*sizeof(GLfloat));\r
diff --git a/BillardGL-starting-resolution.patch b/BillardGL-starting-resolution.patch
new file mode 100755 (executable)
index 0000000..52c3465
--- /dev/null
@@ -0,0 +1,21 @@
+diff -ruN billard-gl-1.75.orig/src/KommandoZeilenParameter.cpp billard-gl-1.75/src/KommandoZeilenParameter.cpp
+--- billard-gl-1.75.orig/src/KommandoZeilenParameter.cpp       2002-04-23 18:04:13.000000000 +0200
++++ billard-gl-1.75/src/KommandoZeilenParameter.cpp    2005-01-22 12:42:31.000000000 +0100
+@@ -144,7 +144,7 @@
+   BandenFaktor         = 0.4;\r
+   KollisionsFaktor     = 0.95;\r
+   ZBufferLoeschen      = 1;\r
+-  BildschirmAufloesung = 800;\r
++  BildschirmAufloesung = 640;\r
+   Farbtiefe            = 16;\r
+   Reflektionen         = 0;\r
+   Sprache              = 0;\r
+@@ -154,7 +154,7 @@
+   TischLampen          = 2;\r
+   GrueneLampe          = 0;\r
\r
+-  FullScreen           = 1;\r
++  FullScreen           = 0;\r
\r
+   EffektLautstaerke    = .5;\r
+   MusikLautstaerke     = .5;\r
This page took 0.107362 seconds and 4 git commands to generate.