From GaProgMan's Wiki
Revision as of 10:27, 5 June 2016 by GaProgMan (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

SmsFixer is an open source console application, written in C#, for processing multiple copies of messages in conversation threads from an SMS backup XML file.

Original author(s) Jamie
Developer(s) Jamie
Development status Active
Written in C#, .NET 4.5
Available in English
License GNU GPLv3

Source Post Mortem

The application uses C# and Dot Net 4.5 and is run from the console.


When the application is run, it checks the folder that it is in for a file called "sms.xml". If this file is present, then it parses the files contents into a list of messages - an example of a message found in the xml file can be found in the following section).

The list of messages is grouped by their body text (selecting all common messages into a separate list of messages. Then the first item in that list is selected and stored in a separate list. This process is done for all messages in the grouped list.

The resulting list is then sorted by date set, and serialised back to an xml file called "sms-noDuplicates.xml" (this is stored in the same folder as the application and the initial XML file.

Project Description

Jamie uses Sms Backup and Restore to keep a backup of his SMS and MMS messages. This particular app backs up all applicable messages and call logs in XML format, and example of which can be seen below:

    <sms protocol="0"
      body="I think I found the penguin button! "
      readable_date="1 Aug 2013 14:30:37"
      contact_name="Vincent Realperson" />

After upgrading the version of Cyanogenmod (which required a full wipe of the software) onto his phone, something became unstable while he was restoring his SMS messages. After the restoration of SMS messages, Jamie found that he had multiple copies of each message for each conversation thread.

A full write up of the issue can be found at his blog here


The latest version of the source code can be found at Jamie's GitHub repository for the project: