Skip to content

Commit 07b6b61

Browse files
committed
[PR #1428] dix: dixfonts: drop unused GetFontPath()
PR: #1428
1 parent de6c485 commit 07b6b61

File tree

2 files changed

+0
-45
lines changed

2 files changed

+0
-45
lines changed

dix/dixfonts.c

Lines changed: 0 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,6 @@ static int num_fpes = 0;
9191
static xfont2_fpe_funcs_rec const **fpe_functions;
9292
static int num_fpe_types = 0;
9393

94-
static unsigned char *font_path_string;
95-
9694
static int num_slept_fpes = 0;
9795
static int size_slept_fpes = 0;
9896
static FontPathElementPtr *slept_fpes = (FontPathElementPtr *) 0;
@@ -1767,44 +1765,6 @@ SetDefaultFontPath(const char *path)
17671765
return err;
17681766
}
17691767

1770-
int
1771-
GetFontPath(ClientPtr client, int *count, int *length, unsigned char **result)
1772-
{
1773-
int access;
1774-
unsigned char *c;
1775-
int len;
1776-
FontPathElementPtr fpe;
1777-
1778-
access = dixCallServerAccessCallback(client, DixGetAttrAccess);
1779-
if (access != Success)
1780-
return access;
1781-
1782-
len = 0;
1783-
for (int i = 0; i < num_fpes; i++) {
1784-
fpe = font_path_elements[i];
1785-
len += fpe->name_length + 1;
1786-
}
1787-
c = realloc(font_path_string, len);
1788-
if (c == NULL) {
1789-
free(font_path_string);
1790-
font_path_string = NULL;
1791-
return BadAlloc;
1792-
}
1793-
1794-
font_path_string = c;
1795-
*length = 0;
1796-
for (int i = 0; i < num_fpes; i++) {
1797-
fpe = font_path_elements[i];
1798-
*c = fpe->name_length;
1799-
*length += *c++;
1800-
memcpy(c, fpe->name, fpe->name_length);
1801-
c += fpe->name_length;
1802-
}
1803-
*count = num_fpes;
1804-
*result = font_path_string;
1805-
return Success;
1806-
}
1807-
18081768
void
18091769
DeleteClientFontStuff(ClientPtr client)
18101770
{

include/dixfont.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -74,11 +74,6 @@ extern _X_EXPORT int SetFontPath(ClientPtr /*client */ ,
7474

7575
extern _X_EXPORT int SetDefaultFontPath(const char * /*path */ );
7676

77-
/* not used by any known external driver, so can be removed soon */
78-
extern _X_EXPORT int GetFontPath(ClientPtr client,
79-
int *count,
80-
int *length, unsigned char **result) _X_DEPRECATED;
81-
8277
extern _X_EXPORT void DeleteClientFontStuff(ClientPtr /*client */ );
8378

8479
/* Quartz support on Mac OS X pulls in the QuickDraw

0 commit comments

Comments
 (0)