chiark / gitweb /
found error in filenames.
authorBernhard <bkubicek@x201.(none)>
Mon, 19 Mar 2012 19:06:58 +0000 (20:06 +0100)
committerBernhard <bkubicek@x201.(none)>
Mon, 19 Mar 2012 19:06:58 +0000 (20:06 +0100)
One array was too short. This had nothing to do with long filenames, other than if they were 12 characters exactly, which could only happen if the extension and the text before were filled completely

Marlin/Configuration_adv.h
Marlin/cardreader.cpp
Marlin/cardreader.h

index 0e42235d64f6bb39de319df6c5f1e1c5d9a6d57a..e2a98248e376db79b530a151d29ab38b93ba7e23 100644 (file)
@@ -162,6 +162,9 @@ const int dropsegments=5; //everything with less than this number of steps will
 // be commented out otherwise
 #define SDCARDDETECTINVERTED 
 
+#ifdef ULTIPANEL
+ #undef SDCARDDETECTINVERTED
+#endif
 //===========================================================================
 //=============================Buffers           ============================
 //===========================================================================
index 4a63f727a18a77944ae7b6720c66d1029c3e8d80..c3ee3e212df15030df46c26302bd98680892c39a 100644 (file)
@@ -53,7 +53,7 @@ void  CardReader::lsDive(const char *prepend,SdFile parent)
  
   while (parent.readDir(p) > 0)
   {
-    if( DIR_IS_SUBDIR(&p) && lsAction!=LS_Count && lsAction!=LS_GetFilename)
+    if( DIR_IS_SUBDIR(&p) && lsAction!=LS_Count && lsAction!=LS_GetFilename) // hence LS_SerialPrint
     {
 
       char path[13*2];
index e56c3a9e6531522193edecaf8098907388edb5e0..5c6e29ad812483f396f8ab24cb3492157d91e801 100644 (file)
@@ -45,7 +45,7 @@ public:
   bool saving;
   bool sdprinting ;  
   bool cardOK ;
-  char filename[11];
+  char filename[12];
   bool filenameIsDir;
   int lastnr; //last number of the autostart;
 private: