File: compiler_errors

package info (click to toggle)
concavity 0.1%2Bdfsg.1-5
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye
  • size: 3,992 kB
  • sloc: cpp: 40,945; makefile: 139; sh: 38
file content (66 lines) | stat: -rw-r--r-- 2,192 bytes parent folder | download | duplicates (5)
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
54
55
56
57
58
59
60
61
62
63
64
65
66
Author: Laszlo Kajan <lkajan@rostlab.org>
Description: fix compiler errors and warnings
Forwarded: http://lists.alioth.debian.org/pipermail/debian-med-packaging/2012-September/017323.html
Forwarded-Comment: Upstream was bcc'd on forwarded email.
--- a/pkgs/PDB/PDBFile.C
+++ b/pkgs/PDB/PDBFile.C
@@ -396,7 +396,7 @@
 {
   // Write all header lines
   for (int i = 0; i < headers.NEntries(); i++) {
-    fprintf(fp, headers.Kth(i));
+    fprintf(fp, "%s", headers.Kth(i));
   }
 
   // Write all models
@@ -444,7 +444,7 @@
     
   // Write all trailing lines
   for (int i = 0; i < trailers.NEntries(); i++) {
-    fprintf(fp, trailers.Kth(i));
+    fprintf(fp, "%s", trailers.Kth(i));
   }
 
   // Return number of models written
@@ -1355,7 +1355,7 @@
     }
 
     // Check jsd files for chain A if chain name is "-" or " " ???
-    if (translate_unnamed_chains && !strcmp(chain_name, "-") || !strcmp(chain_name, " ")) {
+    if (translate_unnamed_chains && ( !strcmp(chain_name, "-") || !strcmp(chain_name, " ") ) ) {
       // Get chain jsd filename
       strcpy(chain_filename, jsd_basename);
       strcat(chain_filename, "_");
--- a/pkgs/R3Shapes/R3Grid.C
+++ b/pkgs/R3Shapes/R3Grid.C
@@ -2151,7 +2151,7 @@
   }
 
   // Read toplbl from file 
-  char toplbl[32];
+  char toplbl[64];
   if (fread(toplbl, sizeof(char), 60, fp) != 60) {
     RNFail("Unable to read toplbl from delphi file: %s\n", filename);
     return 0;
--- a/pkgs/R3Shapes/R3Triangle.C
+++ b/pkgs/R3Shapes/R3Triangle.C
@@ -254,7 +254,7 @@
     RNLength length = 0.0;
     length += R3Distance(v[0]->Position(), v[1]->Position());
     length += R3Distance(v[1]->Position(), v[2]->Position());
-    length += R3Distance(v[2]->Position(), v[3]->Position());
+    length += R3Distance(v[2]->Position(), v[0]->Position());
     return length;
 }
 
--- a/pkgs/PDB/PDBUtil.C
+++ b/pkgs/PDB/PDBUtil.C
@@ -161,7 +161,7 @@
   }
 #else
   // Count atoms on each side of axes for each element type
-  RNScalar sum[3][6] = { 0 };
+  RNScalar sum[3][6] = { { 0 } };
   for (int a = 0; a < atoms.NEntries(); a++) {
     PDBAtom *atom = atoms[a];
     PDBElement *element = atom->Element();