blob: 1d5ba059d7b08166004c62bb0cf8173ec99af03b (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
#include "dbandroidconnection.h"
#include <QDebug>
QByteArray DbAndroidConnection::convertBlob(const QString& value)
{
if (!value.startsWith("X'", Qt::CaseInsensitive) || !value.endsWith("'"))
{
qCritical() << "Invalid BLOB value from Android. Doesn't match BLOB pattern:" << value;
return QByteArray();
}
return QByteArray::fromHex(value.mid(2, value.length() - 3).toLatin1());
}
|