Code review comment for lp:~renatofilho/ubuntu-filemanager-app/fix-network-crash

Renato,

by temporary objects I mean a temporary DirItemInfo created in Location?? classes, example:

void Location::refreshInfo()
{
    if (m_info)
    {
        DirItemInfo *item = newItemInfo(m_info->absoluteFilePath());
        delete m_info;
        m_info = item;
    }
}

Would be changed by:

void Location::refreshInfo()
{
    if (m_info)
    {
        DirItemInfo *item = newItemInfo(m_info->absoluteFilePath());
        *m_info = *item; // current m_info item receives current information
        delete item;
    }
}

I am not sure the operator "=" works properly for all DirItemInfo descendant classes.

« Back to merge proposal