[mythtv] Re: compiling mythtv frontend for cygwin
Mario L
superm1 at gmail.com
Thu Oct 14 18:47:34 UTC 2004
whoops that code should for the small app should have been
int main()
{
QStringList theLIST;
theLIST << "Hello";
theLIST << "World";
for (QStringList::Iterator it = theLIST.begin();it !=
theLIST.end(); ++it )
{
cout<<*it<<endl;
}
return 0;
}
On Thu, 14 Oct 2004 13:46:36 -0500, Mario L <superm1 at gmail.com> wrote:
> Well i have broken it down to for sure that it is iterator problems.
> There are only so many things that you can comment out in there that
> use iterators before you have a non functioning program however :).
> Launching from a command shell with the log "-l logfile.txt" will
> maintain all paths, ex share/mythtv/mysql.txt etc... and log right to
> a file. I have pinpointed the first place it segfaults to main.cpp in
> mythfrontend, meaningly
>
> for (QStringList::Iterator it = verboseOpts.begin();
> it != verboseOpts.end(); ++it )
>
> Of course that line is only reached if you try to use a switch for "-v
> ______", but this is almost the 15th line of the app, there are only
> so many things that could cause it! That verboseOpts.begin() line
> seems to seg fault it. The funny thing is that QT uses that same sort
> of syntax all over with .begin() and .end() in alot of files, with no
> problem. If you try to make a short app using iterators like:
>
> #include <qapplication.h>
> #include <iostream>
> using namespace std;
>
> int main()
> {
> QStringList theLIST;
> theLIST << "Hello";
> theLIST << "World";
> for (QStringList::Iterator it = verboseOpts.begin();it !=
> verboseOpts.end(); ++it )
> {
> cout<<*it<<endl;
> }
> return 0;
> }
>
> There are no issues whatsoever with the above code, so perhaps its not
> even the fact of the using the iterators, but perhaps the text being
> put into the QStringList.
>
> The next instance for myth is in globalsettings.cpp
>
> addSelection(QObject::tr("Desktop Style"), "");
> QStyleFactory factory;
> QStringList list = factory.keys();
> QStringList::iterator iter = list.begin();
> for (; iter != list.end(); iter++ )
> addSelection(*iter);
>
> Again it will segfault at the list.begin() line which makes me think
> that maybe its not actually the text being put in wrong.
>
> Whichever the case, I made a post to the kde-cygwin list in hopes that
> some of the QT experts out there can lend an ear.
>
More information about the mythtv-dev
mailing list