<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Unhandled exception at...]]></title><description><![CDATA[<p>Hallo, ich hab ein kleines Problem mit folgender Funktion...</p>
<pre><code class="language-cpp">void OGLText::Print(unsigned int id, const char *fmt, ...)
{
	char text[256];
	va_list ap;
	if(fmt == NULL)
		return;
	va_start(ap, fmt);
	vsprintf(text, fmt, ap);
	va_end(ap);
	glPushAttrib(GL_LIST_BIT);
	glListBase(base[id] - 32);
	glCallLists(strlen(text), GL_UNSIGNED_BYTE, text);
	glPopAttrib();
}
</code></pre>
<p>damit ruf ich die Funktion auf:</p>
<pre><code class="language-cpp">Text.Print(0, &quot;Test:&quot;);
</code></pre>
<p>funktioniert ohne jegliches Problem, aber wenn ich folgendes aufrufe und was auch bisher immer funktioniert hat:</p>
<pre><code class="language-cpp">Text.Print(0, &quot;Test:%2.0f&quot;, irgend_eine_zahlen_variable);
</code></pre>
<p>bekomme ich immer eine Unhandled exception at...<br />
Im debugger steht für die obige text variable nur &quot;Test:98300000000000000000 usw&quot; drinne. Der Debugger hält bei glListBase() an.</p>
<p>Könnte mir da jemand bitte helfen?</p>
<p>PS: Zur Info, erst seit ich &lt;vector&gt; und using namespace std noch in einer völlig anderen unabhängigen Klasse verwende besteht dieses Problem.</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/121093/unhandled-exception-at</link><generator>RSS for Node</generator><lastBuildDate>Sat, 22 Aug 2026 14:47:07 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/121093.rss" rel="self" type="application/rss+xml"/><pubDate>Mon, 19 Sep 2005 19:15:20 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Unhandled exception at... on Mon, 19 Sep 2005 19:15:20 GMT]]></title><description><![CDATA[<p>Hallo, ich hab ein kleines Problem mit folgender Funktion...</p>
<pre><code class="language-cpp">void OGLText::Print(unsigned int id, const char *fmt, ...)
{
	char text[256];
	va_list ap;
	if(fmt == NULL)
		return;
	va_start(ap, fmt);
	vsprintf(text, fmt, ap);
	va_end(ap);
	glPushAttrib(GL_LIST_BIT);
	glListBase(base[id] - 32);
	glCallLists(strlen(text), GL_UNSIGNED_BYTE, text);
	glPopAttrib();
}
</code></pre>
<p>damit ruf ich die Funktion auf:</p>
<pre><code class="language-cpp">Text.Print(0, &quot;Test:&quot;);
</code></pre>
<p>funktioniert ohne jegliches Problem, aber wenn ich folgendes aufrufe und was auch bisher immer funktioniert hat:</p>
<pre><code class="language-cpp">Text.Print(0, &quot;Test:%2.0f&quot;, irgend_eine_zahlen_variable);
</code></pre>
<p>bekomme ich immer eine Unhandled exception at...<br />
Im debugger steht für die obige text variable nur &quot;Test:98300000000000000000 usw&quot; drinne. Der Debugger hält bei glListBase() an.</p>
<p>Könnte mir da jemand bitte helfen?</p>
<p>PS: Zur Info, erst seit ich &lt;vector&gt; und using namespace std noch in einer völlig anderen unabhängigen Klasse verwende besteht dieses Problem.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/876069</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/876069</guid><dc:creator><![CDATA[VirtualDreams]]></dc:creator><pubDate>Mon, 19 Sep 2005 19:15:20 GMT</pubDate></item><item><title><![CDATA[Reply to Unhandled exception at... on Mon, 19 Sep 2005 20:28:29 GMT]]></title><description><![CDATA[<p>Dass eine Exception auftritt wundert mich zwar, aber es darf natürlich nicht</p>
<pre><code>irgend_eine_zahlen_variable
</code></pre>
<p>sein sondern nur ein Ausdruck vom Typ float oder double.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/876125</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/876125</guid><dc:creator><![CDATA[Ringding]]></dc:creator><pubDate>Mon, 19 Sep 2005 20:28:29 GMT</pubDate></item><item><title><![CDATA[Reply to Unhandled exception at... on Tue, 20 Sep 2005 06:58:48 GMT]]></title><description><![CDATA[<p>Danke, mit float und/oder double klappt es wieder super und ohne Probleme.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/876263</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/876263</guid><dc:creator><![CDATA[VirtualDreams]]></dc:creator><pubDate>Tue, 20 Sep 2005 06:58:48 GMT</pubDate></item></channel></rss>