Index: molecuilder/src/builder.cpp
===================================================================
--- molecuilder/src/builder.cpp	(revision 307fd1c1a8b8349b99eb1c12a97580ea68b1a8a3)
+++ molecuilder/src/builder.cpp	(revision c510a73f7abb99d9b955e6ab83d019f5600be71f)
@@ -691,5 +691,5 @@
 void SaveConfig(char *ConfigFileName, config *configuration, periodentafel *periode, molecule *mol)
 {
-  char filename[255];
+  char filename[MAXSTRINGSIZE];
   ofstream output;
 
@@ -752,5 +752,5 @@
   ofstream output;
   string line;
-  char filename[255];
+  char filename[MAXSTRINGSIZE];
   char *ConfigFileName = NULL;
   char *ElementsFileName = NULL;
Index: molecuilder/src/config.cpp
===================================================================
--- molecuilder/src/config.cpp	(revision 307fd1c1a8b8349b99eb1c12a97580ea68b1a8a3)
+++ molecuilder/src/config.cpp	(revision c510a73f7abb99d9b955e6ab83d019f5600be71f)
@@ -13,9 +13,9 @@
 config::config()
 {
-  mainname = (char *) MallocString(sizeof(char)*255,"config constructor: mainname");
-  defaultpath = (char *) MallocString(sizeof(char)*255,"config constructor: mainname");
-  pseudopotpath = (char *) MallocString(sizeof(char)*255,"config constructor: mainname");
-  configpath = (char *) MallocString(sizeof(char)*255,"config constructor: mainname");
-  configname = (char *) MallocString(sizeof(char)*255,"config constructor: mainname");
+  mainname = (char *) MallocString(sizeof(char)*MAXSTRINGSIZE,"config constructor: mainname");
+  defaultpath = (char *) MallocString(sizeof(char)*MAXSTRINGSIZE,"config constructor: mainname");
+  pseudopotpath = (char *) MallocString(sizeof(char)*MAXSTRINGSIZE,"config constructor: mainname");
+  configpath = (char *) MallocString(sizeof(char)*MAXSTRINGSIZE,"config constructor: mainname");
+  configname = (char *) MallocString(sizeof(char)*MAXSTRINGSIZE,"config constructor: mainname");
   strcpy(mainname,"pcp");
   strcpy(defaultpath,"not specified");
@@ -414,5 +414,5 @@
   char *ptr = NULL;
   int last = -1;
-  for(int i=0;i<255;i++) {
+  for(int i=0;i<MAXSTRINGSIZE;i++) {
     if (filename[i] == '/')
       last = i;
@@ -1168,5 +1168,6 @@
                 case(string_type):
                   if (value != NULL) {
-                    if (maxlength == -1) maxlength = strlen((char *)value); // get maximum size of string array
+                    //if (maxlength == -1) maxlength = strlen((char *)value); // get maximum size of string array
+                    maxlength = MAXSTRINGSIZE;
                     length = maxlength > (dummy-dummy1) ? (dummy-dummy1) : maxlength; // cap at maximum
                     strncpy((char *)value, dummy1, length);  // copy as much
Index: molecuilder/src/defs.hpp
===================================================================
--- molecuilder/src/defs.hpp	(revision 307fd1c1a8b8349b99eb1c12a97580ea68b1a8a3)
+++ molecuilder/src/defs.hpp	(revision c510a73f7abb99d9b955e6ab83d019f5600be71f)
@@ -37,4 +37,7 @@
 enum value_type { string_type, double_type, int_type, row_int, row_double, grid, lower_trigrid, upper_trigrid}; 
 
+// maximum length of any char array
+#define MAXSTRINGSIZE 255
+
 // various standard filenames
 #define DEFAULTCONFIG "main_pcp_linux"
Index: molecuilder/src/moleculelist.cpp
===================================================================
--- molecuilder/src/moleculelist.cpp	(revision 307fd1c1a8b8349b99eb1c12a97580ea68b1a8a3)
+++ molecuilder/src/moleculelist.cpp	(revision c510a73f7abb99d9b955e6ab83d019f5600be71f)
@@ -304,11 +304,11 @@
 {
   ofstream outputFragment;
-  char FragmentName[255];
-  char PathBackup[255];
+  char FragmentName[MAXSTRINGSIZE];
+  char PathBackup[MAXSTRINGSIZE];
   bool result = true;
   bool intermediateResult = true;
   atom *Walker = NULL;
   vector BoxDimension;
-  char TEFilename[255];
+  char TEFilename[MAXSTRINGSIZE];
   char *FragmentNumber;
   int FragmentCounter = 0;
Index: molecuilder/src/molecules.cpp
===================================================================
--- molecuilder/src/molecules.cpp	(revision 307fd1c1a8b8349b99eb1c12a97580ea68b1a8a3)
+++ molecuilder/src/molecules.cpp	(revision c510a73f7abb99d9b955e6ab83d019f5600be71f)
@@ -1892,5 +1892,5 @@
   ifstream KeySetFile;
   stringstream line;
-  char *filename = (char *) Malloc(sizeof(char)*255, "molecule::ParseKeySetFile - filename");
+  char *filename = (char *) Malloc(sizeof(char)*MAXSTRINGSIZE, "molecule::ParseKeySetFile - filename");
   
   if (FragmentList != NULL) { // check list pointer
@@ -1905,8 +1905,8 @@
     // each line represents a new fragment
     int NumberOfFragments = 0;
-    char *buffer = (char *) Malloc(sizeof(char)*255, "molecule::ParseKeySetFile - *buffer");
+    char *buffer = (char *) Malloc(sizeof(char)*MAXSTRINGSIZE, "molecule::ParseKeySetFile - *buffer");
     // 1. scan through file to know number of fragments
     while (!KeySetFile.eof()) {
-      KeySetFile.getline(buffer, 255);
+      KeySetFile.getline(buffer, MAXSTRINGSIZE);
       if (strlen(buffer) > 0) // there is at least on possible number on the parsed line
         NumberOfFragments++;
@@ -1919,5 +1919,5 @@
     NumberOfFragments = 0;
     while ((!KeySetFile.eof()) && (FragmentList->NumberOfMolecules > NumberOfFragments)) {
-      KeySetFile.getline(buffer, 255);
+      KeySetFile.getline(buffer, MAXSTRINGSIZE);
       KeySet CurrentSet;
       if ((strlen(buffer) > 0) && (ScanBufferIntoKeySet(out, buffer, CurrentSet)))  // if at least one valid atom was added, write config
@@ -1946,5 +1946,5 @@
   ofstream AdjacencyFile;
   atom *Walker = NULL;
-  char *filename = (char *) Malloc(sizeof(char)*255, "molecule::StoreAdjacencyToFile - filename");
+  char *filename = (char *) Malloc(sizeof(char)*MAXSTRINGSIZE, "molecule::StoreAdjacencyToFile - filename");
   bool status = true;
 
@@ -1982,5 +1982,5 @@
 bool molecule::CheckAdjacencyFileAgainstMolecule(ofstream *out, char *path, atom **ListOfAtoms, int bondorder)
 {
-  char *filename = (char *) Malloc(sizeof(char)*255, "molecule::CheckAdjacencyFileAgainstMolecule - filename");
+  char *filename = (char *) Malloc(sizeof(char)*MAXSTRINGSIZE, "molecule::CheckAdjacencyFileAgainstMolecule - filename");
   ifstream File;
   bool status = true;
@@ -1996,5 +1996,5 @@
 
     // determine order from file
-    File.getline(filename, 255);    
+    File.getline(filename, MAXSTRINGSIZE);    
     if (bondorder != atoi(&filename[5])) {
       *out << "Bond order desired is " << bondorder << " and does not match one in file " << filename[6] << "." << endl;
@@ -2003,5 +2003,5 @@
       // Parse the file line by line and count the bonds
       while (!File.eof()) {
-        File.getline(filename, 255);
+        File.getline(filename, MAXSTRINGSIZE);
         stringstream line;
         line.str(filename);
Index: molecuilder/src/molecules.hpp
===================================================================
--- molecuilder/src/molecules.hpp	(revision 307fd1c1a8b8349b99eb1c12a97580ea68b1a8a3)
+++ molecuilder/src/molecules.hpp	(revision c510a73f7abb99d9b955e6ab83d019f5600be71f)
@@ -247,6 +247,6 @@
     element *start; //!< start of element list
     element *end;   //!< end of element list
-    char header1[255]; //!< store first header line
-    char header2[255]; //!< store second header line
+    char header1[MAXSTRINGSIZE]; //!< store first header line
+    char header2[MAXSTRINGSIZE]; //!< store second header line
   
   periodentafel();
Index: molecuilder/src/periodentafel.cpp
===================================================================
--- molecuilder/src/periodentafel.cpp	(revision 307fd1c1a8b8349b99eb1c12a97580ea68b1a8a3)
+++ molecuilder/src/periodentafel.cpp	(revision c510a73f7abb99d9b955e6ab83d019f5600be71f)
@@ -175,6 +175,6 @@
     infile.open(filename);
   if (infile != NULL) {
-    infile.getline(header1, 255);
-    infile.getline(header2, 255); // skip first two header lines
+    infile.getline(header1, MAXSTRINGSIZE);
+    infile.getline(header2, MAXSTRINGSIZE); // skip first two header lines
     cout <<  "Parsed elements:";
     while (!infile.eof()) {
Index: pcp/src/defs.h
===================================================================
--- pcp/src/defs.h	(revision 307fd1c1a8b8349b99eb1c12a97580ea68b1a8a3)
+++ pcp/src/defs.h	(revision c510a73f7abb99d9b955e6ab83d019f5600be71f)
@@ -27,5 +27,6 @@
 #define NDIM_NDIM (NDIM*NDIM)		//!< spatial squared
 
-#define MAXDUMMYSTRING (199)	//!< maximum length when mallocting space for string
+
+#define MAXSTRINGSIZE (255)	//!< maximum length when mallocting space for string
 
 //#define mu0 6.691762496807159e-04 //!< permeability of the vacuum in atomic units (a_0 m_e e^{-2}, converted from CODATA values)
Index: pcp/src/helpers.c
===================================================================
--- pcp/src/helpers.c	(revision 307fd1c1a8b8349b99eb1c12a97580ea68b1a8a3)
+++ pcp/src/helpers.c	(revision c510a73f7abb99d9b955e6ab83d019f5600be71f)
@@ -92,5 +92,5 @@
 void* Malloci(size_t size, const char* output, int i)
 {
-  char dummyoutput[MAXDUMMYSTRING];
+  char dummyoutput[MAXSTRINGSIZE];
   void* dummy = (void *) malloc(size);
   if (!dummy) {
@@ -110,5 +110,5 @@
 void* Mallocii(size_t size, const char* output, int i, int j)
 {
-  char dummyoutput[MAXDUMMYSTRING];
+  char dummyoutput[MAXSTRINGSIZE];
   void* dummy = (void *) malloc(size);
   if (!dummy) {
@@ -142,5 +142,5 @@
 void* Realloci(void* pointer, size_t size, const char* output, int i)
 {
-  char dummyoutput[MAXDUMMYSTRING];
+  char dummyoutput[MAXSTRINGSIZE];
   void *dummy = (void *) realloc(pointer, size);
   if (!dummy) {
@@ -161,5 +161,5 @@
 void* Reallocii(void* pointer, size_t size, const char* output, int i, int j)
 {
-  char dummyoutput[MAXDUMMYSTRING];
+  char dummyoutput[MAXSTRINGSIZE];
   void *dummy = (void *) realloc(pointer, size);
   if (!dummy) {
@@ -234,5 +234,5 @@
   int info;
   char processor_name[MPI_MAX_PROCESSOR_NAME];
-  char dummy[MAXDUMMYSTRING];
+  char dummy[MAXSTRINGSIZE];
   P->Par.procs = P->Par.proc[PEPsi]*P->Par.proc[PEGamma];
   P->Par.me = -1; /* eigene Position noch unklar */
Index: pcp/src/init.c
===================================================================
--- pcp/src/init.c	(revision 307fd1c1a8b8349b99eb1c12a97580ea68b1a8a3)
+++ pcp/src/init.c	(revision c510a73f7abb99d9b955e6ab83d019f5600be71f)
@@ -1176,5 +1176,5 @@
   struct LatticeLevel *LevS = R->LevS;
   MPI_Comm_rank(P->Par.comm_ST_Psi, &myPE);  // Determines the rank of the calling process in the communicator
-  //char name[255];
+  //char name[MAXSTRINGSIZE];
   //sprintf(name, ".Psis-%i.all", myPE);
   //FILE *psi;
@@ -1533,11 +1533,11 @@
   /* Namen einlesen */
 
-  P->Files.filename = MallocString(MAXDUMMYSTRING,"ReadParameters: filename");
+  P->Files.filename = MallocString(MAXSTRINGSIZE,"ReadParameters: filename");
 	ParseForParameter(P->Call.out[ReadOut],file, "mainname", 0, 1, 1, string_type, P->Files.filename, 1, critical);
   //debug(P,"mainname");
   CreateMainname(P, filename);
-  P->Files.default_path = MallocString(MAXDUMMYSTRING,"ReadParameters: default_path");
+  P->Files.default_path = MallocString(MAXSTRINGSIZE,"ReadParameters: default_path");
   ParseForParameter(P->Call.out[ReadOut],file, "defaultpath", 0, 1, 1, string_type, P->Files.default_path, 1, critical);
-  P->Files.pseudopot_path = MallocString(MAXDUMMYSTRING,"ReadParameters: pseudopot_path");
+  P->Files.pseudopot_path = MallocString(MAXSTRINGSIZE,"ReadParameters: pseudopot_path");
   ParseForParameter(P->Call.out[ReadOut],file, "pseudopotpath", 0, 1, 1, string_type, P->Files.pseudopot_path, 1, critical);
   ParseForParameter(P->Call.out[ReadOut],file,"ProcPEGamma", 0, 1, 1, int_type, &(P->Par.proc[PEGamma]), 1, critical);
Index: pcp/src/ions.c
===================================================================
--- pcp/src/ions.c	(revision 307fd1c1a8b8349b99eb1c12a97580ea68b1a8a3)
+++ pcp/src/ions.c	(revision c510a73f7abb99d9b955e6ab83d019f5600be71f)
@@ -293,10 +293,10 @@
   I->TotalMass = 0;
   char *free_name, *name;
-  name = free_name = Malloc(255*sizeof(char),"IonsInitRead: Name");
+  name = free_name = Malloc(MAXSTRINGSIZE*sizeof(char),"IonsInitRead: Name");
   for (i=0; i < I->Max_Types; i++) {
   	sprintf(name,"Ion_Type%i",i+1);
     I->I[i].corecorr = NotCoreCorrected;
-    I->I[i].Name = MallocString(255, "IonsInitRead: Name");
-    I->I[i].Symbol = MallocString(255, "IonsInitRead: Symbol");
+    I->I[i].Name = MallocString(MAXSTRINGSIZE, "IonsInitRead: Name");
+    I->I[i].Symbol = MallocString(MAXSTRINGSIZE, "IonsInitRead: Symbol");
 		ParseForParameter(P->Call.out[ReadOut],source, name, 0, 1, 1, int_type, &I->I[i].Max_IonsOfType, 1, critical);
 		ParseForParameter(P->Call.out[ReadOut],source, name, 0, 2, 1, int_type, &I->I[i].Z, 1, critical);
@@ -1014,5 +1014,5 @@
   //struct RunStruct *R = &P->R;
   struct Ions *I = &P->Ion;
-  char filename[255];
+  char filename[MAXSTRINGSIZE];
   FILE *output;
   int is, ia, nr = 0;
Index: pcp/src/opt.c
===================================================================
--- pcp/src/opt.c	(revision 307fd1c1a8b8349b99eb1c12a97580ea68b1a8a3)
+++ pcp/src/opt.c	(revision c510a73f7abb99d9b955e6ab83d019f5600be71f)
@@ -182,5 +182,5 @@
  */
 static int Start_ddd(char *Host, char *program, pid_t pid) {
-  char s[MAXDUMMYSTRING];
+  char s[MAXSTRINGSIZE];
   if (Host) sprintf(s, "ddd -display %s %s %ld &", Host, program, (long int)pid);
   else sprintf(s, "ddd %s %ld &", program, (long int)pid);
@@ -196,5 +196,5 @@
  */
 static int Start_gdb(char *Host, char *program, pid_t pid) {
-  char s[MAXDUMMYSTRING];
+  char s[MAXSTRINGSIZE];
   if (Host) sprintf(s, "xterm -display %s -e gdb %s %ld &", Host, program, (long int)pid);
   else sprintf(s, "xterm -e gdb %s %ld &", program, (long int)pid);
@@ -210,5 +210,5 @@
  */
 static int Start_dbx(char *Host, char *program, pid_t pid) {
-  char s[MAXDUMMYSTRING];
+  char s[MAXSTRINGSIZE];
   program = program;
   if (Host) sprintf(s, "xterm -display %s -e dbx -p %ld &", Host, (long int)pid);
@@ -225,5 +225,5 @@
  */
 static int Start_cvd(char *Host, char *program, pid_t pid) {
-  char s[MAXDUMMYSTRING];
+  char s[MAXSTRINGSIZE];
   program = program;
   if (Host) sprintf(s, "cvd -pid %ld -display %s &", (long int)pid, Host);
@@ -240,5 +240,5 @@
  */
 static int Start_totalview(char *Host, char *program, pid_t pid) {
-  char s[MAXDUMMYSTRING];
+  char s[MAXSTRINGSIZE];
   int myrank = 0;
   MPI_Comm_rank(MPI_COMM_WORLD, &myrank);
@@ -257,5 +257,5 @@
  */
 static int Start_ups(char *Host, char *program, pid_t pid) {
-  char s[MAXDUMMYSTRING];
+  char s[MAXSTRINGSIZE];
   if (Host) sprintf(s, "ups -display %s %s %ld &", Host, program, (long int)pid);
   else sprintf(s, "ups %s %ld &", program, (long int)pid);
@@ -271,5 +271,5 @@
  */
 void StartDebugger(void) {
-  char Host[MAXDUMMYSTRING] = "", Debugger[MAXDUMMYSTRING] = "";
+  char Host[MAXSTRINGSIZE] = "", Debugger[MAXSTRINGSIZE] = "";
   char *host_ptr = Host;
   int (*Debugger_call) (char *, char *, pid_t);
Index: pcp/src/output.c
===================================================================
--- pcp/src/output.c	(revision 307fd1c1a8b8349b99eb1c12a97580ea68b1a8a3)
+++ pcp/src/output.c	(revision c510a73f7abb99d9b955e6ab83d019f5600be71f)
@@ -329,8 +329,8 @@
   
   SpeedMeasure(P,ReadnWriteTime,StartTimeDo);
-  suffixdat = (char *) Malloc(sizeof(char)*255, "OutputSrcPsiDensity: *suffixdat");
-  suffixdoc = (char *) Malloc(sizeof(char)*255, "OutputSrcPsiDensity: *suffixdoc");
+  suffixdat = (char *) Malloc(sizeof(char)*MAXSTRINGSIZE, "OutputSrcPsiDensity: *suffixdat");
+  suffixdoc = (char *) Malloc(sizeof(char)*MAXSTRINGSIZE, "OutputSrcPsiDensity: *suffixdoc");
   sprintf(suffixdat, ".%.254s.L%i", P->R.MinimisationName[type], LevS->LevelNo);
-  strncpy (suffixdoc, suffixdat, 255);
+  strncpy (suffixdoc, suffixdat, MAXSTRINGSIZE);
   // for the various spin cases, output the doc-file if it's process 0
   if (P->Par.me_comm_ST == 0) { // if we are process 0 of SpinDouble or SpinUp&-Down
@@ -338,18 +338,18 @@
     case SpinDouble:
       colorNo = 0;
-      strncat (suffixdat, suffixsrcpsidat, 255-strlen(suffixdat)); 
-      strncat (suffixdoc, suffixsrcpsidoc, 255-strlen(suffixdoc));
+      strncat (suffixdat, suffixsrcpsidat, MAXSTRINGSIZE-strlen(suffixdat)); 
+      strncat (suffixdoc, suffixsrcpsidoc, MAXSTRINGSIZE-strlen(suffixdoc));
       Num =  Lat->Psi.GlobalNo[PsiMaxNoDouble];
       break;
     case SpinUp:
       colorNo = 0;
-      strncat (suffixdat, suffixsrcpsiupdat, 255-strlen(suffixdat)); 
-      strncat (suffixdoc, suffixsrcpsiupdoc, 255-strlen(suffixdoc)); 
+      strncat (suffixdat, suffixsrcpsiupdat, MAXSTRINGSIZE-strlen(suffixdat)); 
+      strncat (suffixdoc, suffixsrcpsiupdoc, MAXSTRINGSIZE-strlen(suffixdoc)); 
       Num = Lat->Psi.GlobalNo[PsiMaxNoUp];
       break;
     case SpinDown:
       colorNo = 1;
-      strncat (suffixdat, suffixsrcpsidowndat, 255-strlen(suffixdat)); 
-      strncat (suffixdoc, suffixsrcpsidowndoc, 255-strlen(suffixdoc)); 
+      strncat (suffixdat, suffixsrcpsidowndat, MAXSTRINGSIZE-strlen(suffixdat)); 
+      strncat (suffixdoc, suffixsrcpsidowndoc, MAXSTRINGSIZE-strlen(suffixdoc)); 
       Num =  Lat->Psi.GlobalNo[PsiMaxNoDown];
       break;
@@ -571,5 +571,5 @@
   int LevelNo, readnr=0;
   int zahl, signal = test ? 1 : 2; // 0 - ok, 1 - test failed, 2 - throw Error
-  char suffixdat[255], suffixdoc[255];
+  char suffixdat[MAXSTRINGSIZE], suffixdoc[MAXSTRINGSIZE];
   int read_type, Num = 0, colorNo = 0;
   char spin[20];
@@ -581,11 +581,11 @@
   SpeedMeasure(P,ReadnWriteTime,StartTimeDo);
   sprintf(suffixdat, ".%.254s.L%i", P->R.MinimisationName[type], LevSNo);
-  strncpy (suffixdoc, suffixdat, 255);
+  strncpy (suffixdoc, suffixdat, MAXSTRINGSIZE);
   // Depending on Psis::SpinType the source psi doc file is opened and header written
   switch (Lat->Psi.PsiST) {
   case SpinDouble:    
     colorNo = 0;
-    strncat (suffixdat, suffixsrcpsidat, 255-strlen(suffixdat)); 
-    strncat (suffixdoc, suffixsrcpsidoc, 255-strlen(suffixdoc));
+    strncat (suffixdat, suffixsrcpsidat, MAXSTRINGSIZE-strlen(suffixdat)); 
+    strncat (suffixdoc, suffixsrcpsidoc, MAXSTRINGSIZE-strlen(suffixdoc));
     strncpy (spin, "GlobalNoSpinDouble", 20); 
     Num = Lat->Psi.GlobalNo[PsiMaxNoDouble];
@@ -593,6 +593,6 @@
   case SpinUp:
     colorNo = 0;
-    strncat (suffixdat, suffixsrcpsiupdat, 255-strlen(suffixdat)); 
-    strncat (suffixdoc, suffixsrcpsiupdoc, 255-strlen(suffixdoc)); 
+    strncat (suffixdat, suffixsrcpsiupdat, MAXSTRINGSIZE-strlen(suffixdat)); 
+    strncat (suffixdoc, suffixsrcpsiupdoc, MAXSTRINGSIZE-strlen(suffixdoc)); 
     strncpy (spin, "GlobalNoSpinUp", 20); 
     Num = Lat->Psi.GlobalNo[PsiMaxNoUp];
@@ -600,6 +600,6 @@
   case SpinDown:
     colorNo = 1;
-    strncat (suffixdat, suffixsrcpsidowndat, 255-strlen(suffixdat)); 
-    strncat (suffixdoc, suffixsrcpsidowndoc, 255-strlen(suffixdoc)); 
+    strncat (suffixdat, suffixsrcpsidowndat, MAXSTRINGSIZE-strlen(suffixdat)); 
+    strncat (suffixdoc, suffixsrcpsidowndoc, MAXSTRINGSIZE-strlen(suffixdoc)); 
     strncpy (spin, "GlobalNoSpinDown", 20); 
     Num = Lat->Psi.GlobalNo[PsiMaxNoDown];
@@ -1051,5 +1051,5 @@
 
   // Open respective file depending on RiemannTensor use
-  suffix = (char *) Malloc(sizeof(char)*255, "CombineOutVisDensity: *suffix");
+  suffix = (char *) Malloc(sizeof(char)*MAXSTRINGSIZE, "CombineOutVisDensity: *suffix");
   switch (Lat->RT.ActualUse) {
   case active:
@@ -1317,5 +1317,5 @@
   int is,ia,i;
   FILE *SrcIonDoc, *SrcIonData;
-  char *suffix = (char *) Malloc(sizeof(char)*255, "CombineOutVisDensity: *suffix");
+  char *suffix = (char *) Malloc(sizeof(char)*MAXSTRINGSIZE, "CombineOutVisDensity: *suffix");
 
   if (!(P->Par.me == 0)) return;
@@ -1493,5 +1493,5 @@
 
   // generate file names
-  suffix = (char *) Malloc(sizeof(char)*255, "OutVisIons: * suffix");
+  suffix = (char *) Malloc(sizeof(char)*MAXSTRINGSIZE, "OutVisIons: * suffix");
   datnamef = (char*)
     malloc(strlen(P->Files.mainname)+strlen(suffixionfor) + 1);
@@ -1776,5 +1776,5 @@
   time(&seconds); // get current time
 
-  filename = (char *) Malloc(sizeof(char)*255, "PlotSrcPlane: *filename");
+  filename = (char *) Malloc(sizeof(char)*MAXSTRINGSIZE, "PlotSrcPlane: *filename");
   switch (Lat->Psi.PsiST) {
     case SpinDouble:    
Index: pcp/src/perturbed.c
===================================================================
--- pcp/src/perturbed.c	(revision 307fd1c1a8b8349b99eb1c12a97580ea68b1a8a3)
+++ pcp/src/perturbed.c	(revision c510a73f7abb99d9b955e6ab83d019f5600be71f)
@@ -2975,5 +2975,5 @@
   }
 
-  suffixchi = (char *) Malloc(sizeof(char)*255, "CalculateMagneticSusceptibility: *suffixchi");
+  suffixchi = (char *) Malloc(sizeof(char)*MAXSTRINGSIZE, "CalculateMagneticSusceptibility: *suffixchi");
   // store symmetrized matrix
   for (in=0;in<NDIM;in++)
@@ -3100,5 +3100,5 @@
   gsl_matrix_complex *H = gsl_matrix_complex_calloc(NDIM,NDIM);
   FILE *SigmaFile;
-  char *suffixsigma = (char *) Malloc(sizeof(char)*255, "CalculateChemicalShieldingByReciprocalCurrentDensity: *suffixsigma");
+  char *suffixsigma = (char *) Malloc(sizeof(char)*MAXSTRINGSIZE, "CalculateChemicalShieldingByReciprocalCurrentDensity: *suffixsigma");
   
   time_t seconds;  
@@ -3400,5 +3400,5 @@
   const int N0 = Lev0->Plan0.plan->local_nx;
   FILE *MomentFile;
-  char *suffixmoment = (char *) Malloc(sizeof(char)*255, "CalculateMagneticMoment: *suffixmoment");
+  char *suffixmoment = (char *) Malloc(sizeof(char)*MAXSTRINGSIZE, "CalculateMagneticMoment: *suffixmoment");
   time_t seconds;  
   time(&seconds); // get current time
@@ -3885,5 +3885,5 @@
   if (!myPE) { // only process 0 writes to file
     // open file
-    filename = (char *) Malloc(sizeof(char)*255, "PlotVectorPlane: *filename");
+    filename = (char *) Malloc(sizeof(char)*MAXSTRINGSIZE, "PlotVectorPlane: *filename");
     sprintf(&filename[0], ".current.L%i.csv", Lev0->LevelNo);
     OpenFile(P, &PlotFile, filename, "w", P->Call.out[ReadOut]);
Index: pcp/src/pseudo.c
===================================================================
--- pcp/src/pseudo.c	(revision 307fd1c1a8b8349b99eb1c12a97580ea68b1a8a3)
+++ pcp/src/pseudo.c	(revision c510a73f7abb99d9b955e6ab83d019f5600be71f)
@@ -483,5 +483,5 @@
   PP->lm_endmax = 0;
   PP->corecorr = NotCoreCorrected;
-  cpiInputFileName = (char *) Malloc(sizeof(char)*255, "InitPseudoRead: *cpiInputFileName");
+  cpiInputFileName = (char *) Malloc(sizeof(char)*MAXSTRINGSIZE, "InitPseudoRead: *cpiInputFileName");
   for (it = 0; it < I->Max_Types; it++) {
     PP->lm_end[it] = I->I[it].l_max*I->I[it].l_max+1-2*I->I[it].l_loc;
Index: pcp/src/wannier.c
===================================================================
--- pcp/src/wannier.c	(revision 307fd1c1a8b8349b99eb1c12a97580ea68b1a8a3)
+++ pcp/src/wannier.c	(revision c510a73f7abb99d9b955e6ab83d019f5600be71f)
@@ -1875,5 +1875,5 @@
   
   if (P->Par.me_comm_ST == 0) {
-    tagname = (char *) Malloc(sizeof(char)*255, "ParseWannierFile: *tagname");
+    tagname = (char *) Malloc(sizeof(char)*MAXSTRINGSIZE, "ParseWannierFile: *tagname");
     if(!OpenFile(P, &SpreadFile, suffix, "r", P->Call.out[ReadOut])) { // check if file exists
       if (MPI_Bcast(&signal,1,MPI_INT,0,P->Par.comm_ST) != MPI_SUCCESS)
