Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
Added source, header and unit testing code for checking an invalid format for Contact...
[xestiaab/.git] / source / contacteditor / ContactDataObject.cpp
index f811e61..854cb56 100644 (file)
@@ -35,8 +35,17 @@ ContactLoadStatus ContactDataObject::LoadFile(wxString Filename){
        }
        
        // Check that the vCard is a valid vCard 4.0 file.
+
+
+       vCard vCard4FormatCheck;
+       
+       vCard4FormatCheck.LoadFile(Filename);
        
+       if (vCard4FormatCheck.Get("VERSION") != wxT("4.0")){
        
+               return CONTACTLOAD_FILEINVALIDFORMAT;
+       
+       }
        
        return CONTACTLOAD_UNITTESTFAIL;
 
Xestia Software Development
Yn Maystri
© 2006 - 2019 Xestia Software Development
Software

Xestia Address Book
Xestia Calendar
Development

Xestia Gelforn
Everything else

About
News
Privacy Policy