projects
/
unres.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
a1f4ddc
)
compinfo.c warning supresion
author
Dawid Jagiela
<lightnir@chem.univ.gda.pl>
Sat, 26 May 2012 15:50:05 +0000
(17:50 +0200)
committer
Dawid Jagiela
<lightnir@chem.univ.gda.pl>
Sat, 26 May 2012 15:50:05 +0000
(17:50 +0200)
source/cluster/wham/src-M/CMakeLists.txt
patch
|
blob
|
history
source/unres/src_CSA/compinfo.c
patch
|
blob
|
history
source/unres/src_MD-M/compinfo.c
patch
|
blob
|
history
source/unres/src_MD/compinfo.c
patch
|
blob
|
history
diff --git
a/source/cluster/wham/src-M/CMakeLists.txt
b/source/cluster/wham/src-M/CMakeLists.txt
index
3926afb
..
cd8871c
100644
(file)
--- a/
source/cluster/wham/src-M/CMakeLists.txt
+++ b/
source/cluster/wham/src-M/CMakeLists.txt
@@
-62,9
+62,9
@@
set(UNRES_CLUSTER_WHAM_M_PP_SRC
# Set comipiler flags for different sourcefiles
#================================================
if (Fortran_COMPILER_NAME STREQUAL "ifort")
# Set comipiler flags for different sourcefiles
#================================================
if (Fortran_COMPILER_NAME STREQUAL "ifort")
- set(FFLAGS0 "-ip -w -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres " )
+ set(FFLAGS0 "-ip -w -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" )
elseif (Fortran_COMPILER_NAME STREQUAL "gfortran")
elseif (Fortran_COMPILER_NAME STREQUAL "gfortran")
- set(FFLAGS0 "-I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres " )
+ set(FFLAGS0 "-I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" )
endif (Fortran_COMPILER_NAME STREQUAL "ifort")
# Add MPI compiler flags
endif (Fortran_COMPILER_NAME STREQUAL "ifort")
# Add MPI compiler flags
diff --git
a/source/unres/src_CSA/compinfo.c
b/source/unres/src_CSA/compinfo.c
index
177dbd3
..
d20b2c9
100644
(file)
--- a/
source/unres/src_CSA/compinfo.c
+++ b/
source/unres/src_CSA/compinfo.c
@@
-14,10
+14,10
@@
time_t Tp;
in=fopen("cinfo.f","r");
out=fopen("cinfo.f.new","w");
in=fopen("cinfo.f","r");
out=fopen("cinfo.f.new","w");
-fgets(buf,498,in);
-fprintf(out,"C DO NOT EDIT THIS FILE - IT HAS BEEN GENERATED BY COMPINFO.C\n");
-fgets(buf,498,in);
-sscanf(&buf[1],"%d %d %d",&iv1,&iv2,&iv3);
+if (fgets(buf,498,in) != NULL)
+ fprintf(out,"C DO NOT EDIT THIS FILE - IT HAS BEEN GENERATED BY COMPINFO.C\n");
+if (fgets(buf,498,in) != NULL)
+ sscanf(&buf[1],"%d %d %d",&iv1,&iv2,&iv3);
iv3++;
fprintf(out,"C %d %d %d\n",iv1,iv2,iv3);
fprintf(out," subroutine cinfo\n");
iv3++;
fprintf(out,"C %d %d %d\n",iv1,iv2,iv3);
fprintf(out," subroutine cinfo\n");
diff --git
a/source/unres/src_MD-M/compinfo.c
b/source/unres/src_MD-M/compinfo.c
index
177dbd3
..
d20b2c9
100644
(file)
--- a/
source/unres/src_MD-M/compinfo.c
+++ b/
source/unres/src_MD-M/compinfo.c
@@
-14,10
+14,10
@@
time_t Tp;
in=fopen("cinfo.f","r");
out=fopen("cinfo.f.new","w");
in=fopen("cinfo.f","r");
out=fopen("cinfo.f.new","w");
-fgets(buf,498,in);
-fprintf(out,"C DO NOT EDIT THIS FILE - IT HAS BEEN GENERATED BY COMPINFO.C\n");
-fgets(buf,498,in);
-sscanf(&buf[1],"%d %d %d",&iv1,&iv2,&iv3);
+if (fgets(buf,498,in) != NULL)
+ fprintf(out,"C DO NOT EDIT THIS FILE - IT HAS BEEN GENERATED BY COMPINFO.C\n");
+if (fgets(buf,498,in) != NULL)
+ sscanf(&buf[1],"%d %d %d",&iv1,&iv2,&iv3);
iv3++;
fprintf(out,"C %d %d %d\n",iv1,iv2,iv3);
fprintf(out," subroutine cinfo\n");
iv3++;
fprintf(out,"C %d %d %d\n",iv1,iv2,iv3);
fprintf(out," subroutine cinfo\n");
diff --git
a/source/unres/src_MD/compinfo.c
b/source/unres/src_MD/compinfo.c
index
177dbd3
..
d20b2c9
100644
(file)
--- a/
source/unres/src_MD/compinfo.c
+++ b/
source/unres/src_MD/compinfo.c
@@
-14,10
+14,10
@@
time_t Tp;
in=fopen("cinfo.f","r");
out=fopen("cinfo.f.new","w");
in=fopen("cinfo.f","r");
out=fopen("cinfo.f.new","w");
-fgets(buf,498,in);
-fprintf(out,"C DO NOT EDIT THIS FILE - IT HAS BEEN GENERATED BY COMPINFO.C\n");
-fgets(buf,498,in);
-sscanf(&buf[1],"%d %d %d",&iv1,&iv2,&iv3);
+if (fgets(buf,498,in) != NULL)
+ fprintf(out,"C DO NOT EDIT THIS FILE - IT HAS BEEN GENERATED BY COMPINFO.C\n");
+if (fgets(buf,498,in) != NULL)
+ sscanf(&buf[1],"%d %d %d",&iv1,&iv2,&iv3);
iv3++;
fprintf(out,"C %d %d %d\n",iv1,iv2,iv3);
fprintf(out," subroutine cinfo\n");
iv3++;
fprintf(out,"C %d %d %d\n",iv1,iv2,iv3);
fprintf(out," subroutine cinfo\n");