[kde-solaris] Problem compiling kdeadmin 3.1

Devendra Deshpande kde-solaris@mail.kde.org
Tue Feb 4 06:32:00 2003


On Mon,  3 Feb 2003 20:17:35 +0100 Laurent Blume <laurent@elanor.org>
wrote:
>

> After having a look at the source, it seems it's right:
>     quotafilename = QString("%1%2%3")
>                           .arg(mt->mnt_mountp)
>                           .arg((mt->mnt_mountp[strlen(mt->mnt_mountp)
>                           - 1] ==
> '/') ? "" : "/")
>                           .arg(_KU_QUOTAFILENAME);
> 
> mt is an mnttab struct, in which mnt_mountp is a char*, and there is
> no method to handle that in /opt/qt/include/qstring.h
> 
> Anyone has an idea where I went wrong ??

I modified that as:

    quotafilename = QString::fromLatin1("%1%2%3")
                          .arg(QString::fromLatin1(mt->mnt_mountp))
                         
.arg(QString::fromLatin1((mt->mnt_mountp[strlen(mt->mnt_mountp) - 1] ==
'/') ? "" : "/"))                         
.arg(QString::fromLatin1(_KU_QUOTAFILENAME)); 

and it worked for me!

Thanks,
Devendra