<html>
<head>
<base href="https://bugs.freedesktop.org/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - Segfault in glGetActiveUniformName"
href="https://bugs.freedesktop.org/show_bug.cgi?id=86594">86594</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Segfault in glGetActiveUniformName
</td>
</tr>
<tr>
<th>Product</th>
<td>Mesa
</td>
</tr>
<tr>
<th>Version</th>
<td>10.3
</td>
</tr>
<tr>
<th>Hardware</th>
<td>x86-64 (AMD64)
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux (All)
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>major
</td>
</tr>
<tr>
<th>Priority</th>
<td>medium
</td>
</tr>
<tr>
<th>Component</th>
<td>Mesa core
</td>
</tr>
<tr>
<th>Assignee</th>
<td>mesa-dev@lists.freedesktop.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>simon@gimp.org
</td>
</tr></table>
<p>
<div>
<pre>I am trying to get some information about a compiled GL shader program, in
particular I need to get information about the Uniform Variables used.
The code I use is this:
glGetProgramiv (program, GL_ACTIVE_UNIFORMS, &n_uniforms);
fprintf (stderr, "%d uniforms:\n", n_uniforms);
for (i = 0; i < n_uniforms; i++)
{
glGetActiveUniformName (program, i, 79, &namelen, name);
name[namelen] = '\0';
fprintf (stderr, " %2d: %s\n", i, name);
}
I get a segfault within glGetActiveUniformName, something is wrong here. The
same code works fine with the NVidia proprietary drivers.
Some more information:
GL_VERSION : 2.1 Mesa 10.3.2
GL_VENDOR : Intel Open Source Technology Center
GL_RENDERER : Mesa DRI Intel(R) Ironlake Mobile
GLEW_VERSION : 1.10.0
GLSL VERSION : 1.20
This is using debian unstable with libgl1-mesa-glx:amd64, 10.3.2-1, amd64
Valgrind is not really helpful, even with debug symbols installed:
==27042== Process terminating with default action of signal 11 (SIGSEGV)
==27042== Bad permissions for mapped region at address 0x0
==27042== at 0x0: ???
==27042== by 0x402BFF: main (shadertoy.c:458)
==27042==</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>