removed test query and abort() in t_assert

This commit is contained in:
John Preston 2015-12-28 01:17:05 +03:00
parent 9a1798f043
commit 7ba845ac74
2 changed files with 1 additions and 3 deletions

View File

@ -85,7 +85,7 @@ void logWrite(const QString &v);
inline void t_noop() {}
inline void t_assert_fail(const char *condition, const char *file, int32 line) {
LOG(("Assertion Failed! \"%1\" %2:%3").arg(condition).arg(file).arg(line));
abort();
*(int*)0 = 0;
}
#define t_assert(cond) ((!(cond)) ? t_assert_fail(#cond, __FILE__, __LINE__) : t_noop())

View File

@ -1341,8 +1341,6 @@ void DocumentOpenLink::doOpen(DocumentData *data, ActionOnLoad action) {
HistoryItem *item = App::hoveredLinkItem() ? App::hoveredLinkItem() : (App::contextItem() ? App::contextItem() : 0);
MTP::send(MTPmessages_SendMedia(MTP_int(0), item->history()->peer->input, MTP_int(0), MTP_inputMediaDocument(MTP_inputDocument(MTP_long(data->id), MTP_long(data->access))), MTP_long(MTP::nonce<uint64>()), MTPnullMarkup));
bool playMusic = data->song() && audioPlayer() && item;
bool playAnimation = data->isAnimation() && item && item->getMedia();
const FileLocation &location(data->location(true));