The occosional warning cleanup;
[blender.git] / source / blender / src / headerbuttons.c
index 57d52edc1093cbf47a2a5493f7e22d6327a6b2d0..6d9e216c47af887311c814d4e2446850b71654ca 100644 (file)
@@ -1294,7 +1294,7 @@ void do_global_buttons(unsigned short event)
                else if(G.buts->mainb==CONTEXT_EDITING) {
                        SculptData *sd= &G.scene->sculptdata;
                        if(sd && sd->texact != -1) {
-                               if(sd->mtex[sd->texact]) autotexname(sd->mtex[sd->texact]);
+                               if(sd->mtex[sd->texact]) autotexname(sd->mtex[sd->texact]->tex);
 
                                BIF_undo_push("Auto name");
                                allqueue(REDRAWBUTSEDIT, 0);