Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 189255
Collapse All | Expand All

(-)konversation-1.0.1/konversation/src/channel.cpp (-1 / +1 lines)
Lines 890-896 Link Here
890
    }
890
    }
891
891
892
    // Send all strings, one after another
892
    // Send all strings, one after another
893
    QStringList outList=QStringList::split('\n',outputAll);
893
    QStringList outList=QStringList::split(QRegExp("[\r\n]+"),outputAll);
894
    for(unsigned int index=0;index<outList.count();index++)
894
    for(unsigned int index=0;index<outList.count();index++)
895
    {
895
    {
896
        QString output(outList[index]);
896
        QString output(outList[index]);
(-)konversation-1.0.1/konversation/src/konvdcop.cpp (-2 / +10 lines)
Lines 82-96 Link Here
82
    emit dcopMultiServerRaw("me " + message);
82
    emit dcopMultiServerRaw("me " + message);
83
}
83
}
84
84
85
void KonvDCOP::say(const QString& server,const QString& target,const QString& command)
85
void KonvDCOP::say(const QString& _server,const QString& _target,const QString& _command)
86
{
86
{
87
    //Sadly, copy on write doesn't exist with QString::replace
88
    QString server(_server), target(_target), command(_command);
89
87
    // TODO: this just masks a greater problem - Server::addQuery will return a query for '' --argonel
90
    // TODO: this just masks a greater problem - Server::addQuery will return a query for '' --argonel
88
    // TODO: other DCOP calls need argument checking too --argonel
91
    // TODO: other DCOP calls need argument checking too --argonel
89
    if (server.isEmpty() || target.isEmpty() || command.isEmpty())
92
    if (server.isEmpty() || target.isEmpty() || command.isEmpty())
90
        kdDebug() <<  "KonvDCOP::say() requires 3 arguments." << endl;
93
        kdDebug() <<  "KonvDCOP::say() requires 3 arguments." << endl;
91
    else
94
    else
92
    {
95
    {
93
        kdDebug() << "KonvDCOP::say()" << endl;
96
        command.replace('\n',"\\n");
97
        command.replace('\r',"\\r");
98
        target.remove('\n');
99
        target.remove('\r');
100
        server.remove('\n');
101
        server.remove('\r');
94
        // Act as if the user typed it
102
        // Act as if the user typed it
95
        emit dcopSay(server,target,command);
103
        emit dcopSay(server,target,command);
96
    }
104
    }

Return to bug 189255