Remove dot at the end of filename without extension
[reactos.git] / reactos / drivers / fs / cdfs / misc.c
index dfa4918..49f2741 100644 (file)
  *  along with this program; if not, write to the Free Software
  *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
-/* $Id: misc.c,v 1.9 2004/11/06 13:41:58 ekohl Exp $
+/* $Id$
  *
  * COPYRIGHT:        See COPYING in the top level directory
  * PROJECT:          ReactOS kernel
  * FILE:             services/fs/cdfs/misc.c
  * PURPOSE:          CDROM (ISO 9660) filesystem driver
  * PROGRAMMER:       Eric Kohl
- * UPDATE HISTORY: 
+ * UPDATE HISTORY:
  */
 
 /* INCLUDES *****************************************************************/
 
-#include <ddk/ntddk.h>
+#include "cdfs.h"
 
 #define NDEBUG
 #include <debug.h>
 
-#include "cdfs.h"
-
-
 /* FUNCTIONS ****************************************************************/
 
 VOID
@@ -53,6 +50,11 @@ CdfsSwapString(PWCHAR Out,
       if (t[i+1] == 0 && t[i] == ';')
        break;
     }
+  if ((i>2)&&(t[i-2] == '.'))
+  {
+    t[i-2] = 0;
+    t[i-1] = 0;
+  }
   t[i] = 0;
   t[i+1] = 0;
 }