Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Poirier <theeth@yahoo.com>2006-02-19 21:41:33 +0300
committerMartin Poirier <theeth@yahoo.com>2006-02-19 21:41:33 +0300
commit012f56c3d60a250c8915c85d39d73fddf2590e57 (patch)
treecf553f3a82a52c95140835b27ed101d0f3af395d /source/blender/src/headerbuttons.c
parentda6b87abb116b6e2d76c1c40aaaffbf9e14f59c9 (diff)
Patch: [ #3283 ] strcat --> sprintf
Less yuckiness!
Diffstat (limited to 'source/blender/src/headerbuttons.c')
-rw-r--r--source/blender/src/headerbuttons.c45
1 files changed, 23 insertions, 22 deletions
diff --git a/source/blender/src/headerbuttons.c b/source/blender/src/headerbuttons.c
index 8955794b755..ed3cadc9dbc 100644
--- a/source/blender/src/headerbuttons.c
+++ b/source/blender/src/headerbuttons.c
@@ -184,41 +184,42 @@
char *windowtype_pup(void)
{
static char string[1024];
+ char *str = string;
- strcpy(string, "Window type:%t"); //14
- strcat(string, "|3D View %x1"); //30
+ str += sprintf(str, "%s", "Window type:%t"); //14
+ str += sprintf(str, "%s", "|3D View %x1"); //30
- strcat(string, "|%l"); // 33
+ str += sprintf(str, "%s", "|%l"); // 33
- strcat(string, "|Ipo Curve Editor %x2"); //54
- strcat(string, "|Action Editor %x12"); //73
- strcat(string, "|NLA Editor %x13"); //94
+ str += sprintf(str, "%s", "|Ipo Curve Editor %x2"); //54
+ str += sprintf(str, "%s", "|Action Editor %x12"); //73
+ str += sprintf(str, "%s", "|NLA Editor %x13"); //94
- strcat(string, "|%l"); //97
+ str += sprintf(str, "%s", "|%l"); //97
- strcat(string, "|UV/Image Editor %x6"); //117
+ str += sprintf(str, "%s", "|UV/Image Editor %x6"); //117
- strcat(string, "|Video Sequence Editor %x8"); //143
- strcat(string, "|Timeline %x15"); //163
- strcat(string, "|Audio Window %x11"); //163
- strcat(string, "|Text Editor %x9"); //179
+ str += sprintf(str, "%s", "|Video Sequence Editor %x8"); //143
+ str += sprintf(str, "%s", "|Timeline %x15"); //163
+ str += sprintf(str, "%s", "|Audio Window %x11"); //163
+ str += sprintf(str, "%s", "|Text Editor %x9"); //179
- strcat(string, "|%l"); //192
+ str += sprintf(str, "%s", "|%l"); //192
- strcat(string, "|User Preferences %x7"); //213
- strcat(string, "|Outliner %x3"); //232
- strcat(string, "|Buttons Window %x4"); //251
- strcat(string, "|Node Editor %x16");
+ str += sprintf(str, "%s", "|User Preferences %x7"); //213
+ str += sprintf(str, "%s", "|Outliner %x3"); //232
+ str += sprintf(str, "%s", "|Buttons Window %x4"); //251
+ str += sprintf(str, "%s", "|Node Editor %x16");
- strcat(string, "|%l"); //254
+ str += sprintf(str, "%s", "|%l"); //254
- strcat(string, "|Image Browser %x10"); //273
- strcat(string, "|File Browser %x5"); //290
+ str += sprintf(str, "%s", "|Image Browser %x10"); //273
+ str += sprintf(str, "%s", "|File Browser %x5"); //290
- strcat(string, "|%l"); //293
+ str += sprintf(str, "%s", "|%l"); //293
- strcat(string, "|Scripts Window %x14"); //313
+ str += sprintf(str, "%s", "|Scripts Window %x14"); //313
return (string);
}