]> git.cworth.org Git - vogl/blobdiff - src/voglcommon/vogl_gl_replayer.cpp
improving error message
[vogl] / src / voglcommon / vogl_gl_replayer.cpp
index 0df3d49b2b0ff15ff54e71ece80cd7ec708ae193..2f7ef0abf6351fd3ea87901d9e009c9b7e602292 100644 (file)
@@ -1266,7 +1266,10 @@ GLint vogl_gl_replayer::determine_uniform_replay_location(GLuint trace_program,
 {
     VOGL_FUNC_TRACER
 
-    GLint replay_location = trace_location;
+    // Seems better to return -1 when we can't find the uniform (which can happen if the driver optimizes the program differently vs. tracing).
+    // Otherwise, we can pass an invalid handle down to the driver and this will crash AMD's fglrx.
+    //GLint replay_location = trace_location;
+    GLint replay_location = -1;
 
     glsl_program_hash_map::iterator it = get_shared_state()->m_glsl_program_hash_map.find(trace_program);
     if (it == get_shared_state()->m_glsl_program_hash_map.end())
@@ -3988,7 +3991,7 @@ vogl_gl_replayer::status_t vogl_gl_replayer::process_gl_entrypoint_packet_intern
         if (!vogl_display_list_state::is_call_listable(entrypoint_id, trace_packet))
         {
             if (!g_vogl_entrypoint_descs[entrypoint_id].m_whitelisted_for_displaylists)
-                process_entrypoint_error("%s: Failed serializing trace packet into display list shadow! Call is not listable.\n", VOGL_FUNCTION_NAME);
+                process_entrypoint_error("%s: Failed serializing trace packet into display list shadow! Call is not whitelisted for display list usage by vogl.\n", VOGL_FUNCTION_NAME);
             else
                 process_entrypoint_warning("%s: Failed serializing trace packet into display list shadow! Call with these parameters is not listable.\n", VOGL_FUNCTION_NAME);
         }