View | Details | Raw Unified | Return to bug 83426
Collapse All | Expand All

(-)lib/libvgl/Makefile (+2 lines)
Lines 38-41 Link Here
38
		vgl.3 VGLSetXY.3 \
38
		vgl.3 VGLSetXY.3 \
39
		vgl.3 VGLTextSetFontFile.3
39
		vgl.3 VGLTextSetFontFile.3
40
40
41
WARNS+=		2
42
41
.include <bsd.lib.mk>
43
.include <bsd.lib.mk>
(-)lib/libvgl/text.c (-1 / +7 lines)
Lines 63-68 Link Here
63
    fread(&VGLTextFont->Height, 1 , 1, fd);
63
    fread(&VGLTextFont->Height, 1 , 1, fd);
64
    VGLTextFont->BitmapArray = 
64
    VGLTextFont->BitmapArray = 
65
      (byte*)malloc(256*((VGLTextFont->Width + 7)/8)*VGLTextFont->Height);
65
      (byte*)malloc(256*((VGLTextFont->Width + 7)/8)*VGLTextFont->Height);
66
    if (VGLTextFont->BitmapArray == NULL) {
67
	free(VGLTextFont);
68
	VGLTextFont = NULL;
69
	fclose(fd);
70
	return(1);
71
    }
66
    fread(VGLTextFont->BitmapArray, 1, 
72
    fread(VGLTextFont->BitmapArray, 1, 
67
      (256*VGLTextFont->Width* VGLTextFont->Height), fd);
73
      (256*VGLTextFont->Width* VGLTextFont->Height), fd);
68
    fclose(fd);
74
    fclose(fd);
Lines 122-128 Link Here
122
VGLBitmapString(VGLBitmap *Object, int x, int y, char *str, 
128
VGLBitmapString(VGLBitmap *Object, int x, int y, char *str, 
123
		byte fgcol, byte bgcol, int fill, int dir)
129
		byte fgcol, byte bgcol, int fill, int dir)
124
{
130
{
125
  int pos;
131
  size_t pos;
126
132
127
  for (pos=0; pos<strlen(str); pos++) {
133
  for (pos=0; pos<strlen(str); pos++) {
128
    switch (dir) {
134
    switch (dir) {

Return to bug 83426