<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: GdkPixbuf woes</title>
	<atom:link href="http://www.sebruiz.net/354/feed" rel="self" type="application/rss+xml" />
	<link>http://www.sebruiz.net/354</link>
	<description></description>
	<lastBuildDate>Tue, 09 Mar 2010 09:38:19 +0000</lastBuildDate>
	
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Gustavo Noronha</title>
		<link>http://www.sebruiz.net/354/comment-page-1#comment-42721</link>
		<dc:creator>Gustavo Noronha</dc:creator>
		<pubDate>Sat, 14 Mar 2009 21:27:16 +0000</pubDate>
		<guid isPermaLink="false">http://www.sebruiz.net/?p=354#comment-42721</guid>
		<description>Have you tried running the test program in gdb? If you do it with G_DEBUG=fatal_criticals set, gdb will stop on the critical messages, so you can use bt, and walk up in the frame stack, which may help you figure out what&#039;s going wrong.

I&#039;m betting some kind of initialization, but do you use multiple threads? You may have to use GDK_THREADS_ENTER()/GDK_THREADS_LEAVE(); note that GTK /GDK are not thread-safe, they&#039;re only thread-aware.</description>
		<content:encoded><![CDATA[<p>Have you tried running the test program in gdb? If you do it with G_DEBUG=fatal_criticals set, gdb will stop on the critical messages, so you can use bt, and walk up in the frame stack, which may help you figure out what&#8217;s going wrong.</p>
<p>I&#8217;m betting some kind of initialization, but do you use multiple threads? You may have to use GDK_THREADS_ENTER()/GDK_THREADS_LEAVE(); note that GTK /GDK are not thread-safe, they&#8217;re only thread-aware.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Seb</title>
		<link>http://www.sebruiz.net/354/comment-page-1#comment-42686</link>
		<dc:creator>Seb</dc:creator>
		<pubDate>Sat, 14 Mar 2009 03:06:05 +0000</pubDate>
		<guid isPermaLink="false">http://www.sebruiz.net/?p=354#comment-42686</guid>
		<description>Hey everyone, thanks for all the replies. Here&#039;s the progress:

a) I know what all of the assertions mean, literally. I can&#039;t figure out what is causing them though.
b) The test code (which is a c program) works well both when compiled in a plain c   prog as well as a Qt wrapper with a GUI thread and all.
c) Seems like I&#039;m going to have to run through valgrind.
d) @pfee: I like your suggestion, but this seems like a very arduous task considering the size of an application like Amarok.</description>
		<content:encoded><![CDATA[<p>Hey everyone, thanks for all the replies. Here&#8217;s the progress:</p>
<p>a) I know what all of the assertions mean, literally. I can&#8217;t figure out what is causing them though.<br />
b) The test code (which is a c program) works well both when compiled in a plain c   prog as well as a Qt wrapper with a GUI thread and all.<br />
c) Seems like I&#8217;m going to have to run through valgrind.<br />
d) @pfee: I like your suggestion, but this seems like a very arduous task considering the size of an application like Amarok.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Michael Pyne</title>
		<link>http://www.sebruiz.net/354/comment-page-1#comment-42678</link>
		<dc:creator>Michael Pyne</dc:creator>
		<pubDate>Sat, 14 Mar 2009 01:24:01 +0000</pubDate>
		<guid isPermaLink="false">http://www.sebruiz.net/?p=354#comment-42678</guid>
		<description>Seb,

Do you use a 64-bit setup?  If so, make sure that those NULLs are being cast into a pointer type and see if that changes anything.  Recent glibcs should automatically use the gcc-extension null pointer instead of 0 which means this shouldn&#039;t be an issue but you never know.

If it still doesn&#039;t work, try compiling the testcase in C   mode instead of using C and see if it crashes.  If so, the problem is a difference between C   and C compilation.</description>
		<content:encoded><![CDATA[<p>Seb,</p>
<p>Do you use a 64-bit setup?  If so, make sure that those NULLs are being cast into a pointer type and see if that changes anything.  Recent glibcs should automatically use the gcc-extension null pointer instead of 0 which means this shouldn&#8217;t be an issue but you never know.</p>
<p>If it still doesn&#8217;t work, try compiling the testcase in C   mode instead of using C and see if it crashes.  If so, the problem is a difference between C   and C compilation.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Michael</title>
		<link>http://www.sebruiz.net/354/comment-page-1#comment-42670</link>
		<dc:creator>Michael</dc:creator>
		<pubDate>Fri, 13 Mar 2009 15:45:13 +0000</pubDate>
		<guid isPermaLink="false">http://www.sebruiz.net/?p=354#comment-42670</guid>
		<description>Agree with purple-bobby&#039;s ideas. Perhaps you aren&#039;t initializing everything that needs to be initialized.

&gt; assertion `src != NULL&#039; failed
This means that src == NULL. Perhaps src needs to be initialized somewhere.

&gt; g_object_unref: assertion `G_IS_OBJECT (object)’ failed
G_IS_OBJECT, if I&#039;m reading this correctly, checks if a certain value is, in fact, a GObject. Perhaps the value is again NULL?</description>
		<content:encoded><![CDATA[<p>Agree with purple-bobby&#8217;s ideas. Perhaps you aren&#8217;t initializing everything that needs to be initialized.</p>
<p>&gt; assertion `src != NULL&#8217; failed<br />
This means that src == NULL. Perhaps src needs to be initialized somewhere.</p>
<p>&gt; g_object_unref: assertion `G_IS_OBJECT (object)’ failed<br />
G_IS_OBJECT, if I&#8217;m reading this correctly, checks if a certain value is, in fact, a GObject. Perhaps the value is again NULL?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Anders Brander</title>
		<link>http://www.sebruiz.net/354/comment-page-1#comment-42668</link>
		<dc:creator>Anders Brander</dc:creator>
		<pubDate>Fri, 13 Mar 2009 14:56:57 +0000</pubDate>
		<guid isPermaLink="false">http://www.sebruiz.net/?p=354#comment-42668</guid>
		<description>... and maybe even:
g_type_init();</description>
		<content:encoded><![CDATA[<p>&#8230; and maybe even:<br />
g_type_init();</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Anders Brander</title>
		<link>http://www.sebruiz.net/354/comment-page-1#comment-42667</link>
		<dc:creator>Anders Brander</dc:creator>
		<pubDate>Fri, 13 Mar 2009 14:55:36 +0000</pubDate>
		<guid isPermaLink="false">http://www.sebruiz.net/?p=354#comment-42667</guid>
		<description>Maybe this is a stupid question...

Did you remember to call the needed &quot;G-initializers&quot;?

gtk_init(&amp;argc, &amp;argv);

and maybe

g_threads_init(NULL);</description>
		<content:encoded><![CDATA[<p>Maybe this is a stupid question&#8230;</p>
<p>Did you remember to call the needed &#8220;G-initializers&#8221;?</p>
<p>gtk_init(&amp;argc, &amp;argv);</p>
<p>and maybe</p>
<p>g_threads_init(NULL);</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Kevin Kofler</title>
		<link>http://www.sebruiz.net/354/comment-page-1#comment-42666</link>
		<dc:creator>Kevin Kofler</dc:creator>
		<pubDate>Fri, 13 Mar 2009 14:53:48 +0000</pubDate>
		<guid isPermaLink="false">http://www.sebruiz.net/?p=354#comment-42666</guid>
		<description>Have you tried running it through Valgrind yet?</description>
		<content:encoded><![CDATA[<p>Have you tried running it through Valgrind yet?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: purple-bobby</title>
		<link>http://www.sebruiz.net/354/comment-page-1#comment-42665</link>
		<dc:creator>purple-bobby</dc:creator>
		<pubDate>Fri, 13 Mar 2009 14:20:33 +0000</pubDate>
		<guid isPermaLink="false">http://www.sebruiz.net/?p=354#comment-42665</guid>
		<description>If the working code is open-source, can you not look there.

Does some instance of a class need new-ing, and you are using an uninitialised version of the object.

Your first error says (to me) you do NOT have a buffer or source file open for the library to use or read.

Is something initialised and memory allocated in one thread or process, to which another thread or process does not have access to?

The second error, suggests that some incorrect object (or NULL) has been cast into the object reference, and perhaps does not supply a property or method needed.

The third error says your image buffer is the wrong size, it seems to suggest that you do not have an image buffer or your image is a different type/size to the one the image buffer was created for. I would expect an RGB image for static artwork.

On line 28 of your snippet, what if the file was not opened? Would it return NULL? Your seem to be checking pixbuf, but not filename.</description>
		<content:encoded><![CDATA[<p>If the working code is open-source, can you not look there.</p>
<p>Does some instance of a class need new-ing, and you are using an uninitialised version of the object.</p>
<p>Your first error says (to me) you do NOT have a buffer or source file open for the library to use or read.</p>
<p>Is something initialised and memory allocated in one thread or process, to which another thread or process does not have access to?</p>
<p>The second error, suggests that some incorrect object (or NULL) has been cast into the object reference, and perhaps does not supply a property or method needed.</p>
<p>The third error says your image buffer is the wrong size, it seems to suggest that you do not have an image buffer or your image is a different type/size to the one the image buffer was created for. I would expect an RGB image for static artwork.</p>
<p>On line 28 of your snippet, what if the file was not opened? Would it return NULL? Your seem to be checking pixbuf, but not filename.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Lamarque</title>
		<link>http://www.sebruiz.net/354/comment-page-1#comment-42664</link>
		<dc:creator>Lamarque</dc:creator>
		<pubDate>Fri, 13 Mar 2009 14:00:41 +0000</pubDate>
		<guid isPermaLink="false">http://www.sebruiz.net/?p=354#comment-42664</guid>
		<description>It can be a define or environment variable defined in Amarok too. Last year I had a problem with a cryptography code that worked when I tested in my computer but when I used it in the production environment it did not. In the end I found out the problem was the _MALLOC_PERTURB environment variable that was set in the production environment. I unset the variable and everything worked.</description>
		<content:encoded><![CDATA[<p>It can be a define or environment variable defined in Amarok too. Last year I had a problem with a cryptography code that worked when I tested in my computer but when I used it in the production environment it did not. In the end I found out the problem was the _MALLOC_PERTURB environment variable that was set in the production environment. I unset the variable and everything worked.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: pfee</title>
		<link>http://www.sebruiz.net/354/comment-page-1#comment-42662</link>
		<dc:creator>pfee</dc:creator>
		<pubDate>Fri, 13 Mar 2009 13:46:19 +0000</pubDate>
		<guid isPermaLink="false">http://www.sebruiz.net/?p=354#comment-42662</guid>
		<description>I don&#039;t know about the libraries you&#039;re using, but perhaps you have multiple definitions of the same symbols present.  This may mean you&#039;re calling some functions from one library and some from others.

ldd will show immediate dependencies, but libraries loaded via dlopen() won&#039;t be shown.  For that, lsof may help.

Armed with a list of libraries, you could use nm to find the symbols in each library, then look for duplicates.

Multiple similarly named libraries or duplicate symbols would be suspicious and may be your problem.

Hope that helps.</description>
		<content:encoded><![CDATA[<p>I don&#8217;t know about the libraries you&#8217;re using, but perhaps you have multiple definitions of the same symbols present.  This may mean you&#8217;re calling some functions from one library and some from others.</p>
<p>ldd will show immediate dependencies, but libraries loaded via dlopen() won&#8217;t be shown.  For that, lsof may help.</p>
<p>Armed with a list of libraries, you could use nm to find the symbols in each library, then look for duplicates.</p>
<p>Multiple similarly named libraries or duplicate symbols would be suspicious and may be your problem.</p>
<p>Hope that helps.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
