forked from len0rd/rockbox
Add a bit more debug output to checkwps
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28552 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
d0ffa9315f
commit
f74a1aab64
2 changed files with 7 additions and 0 deletions
|
@ -1115,12 +1115,17 @@ static bool load_skin_bmp(struct wps_data *wps_data, struct bitmap *bitmap, char
|
||||||
|
|
||||||
fd = open(img_path, O_RDONLY);
|
fd = open(img_path, O_RDONLY);
|
||||||
if (fd < 0)
|
if (fd < 0)
|
||||||
|
{
|
||||||
|
DEBUGF("Couldn't open %s\n", img_path);
|
||||||
return false;
|
return false;
|
||||||
|
}
|
||||||
size_t buf_size = read_bmp_fd(fd, bitmap, 0,
|
size_t buf_size = read_bmp_fd(fd, bitmap, 0,
|
||||||
format|FORMAT_RETURN_SIZE, NULL);
|
format|FORMAT_RETURN_SIZE, NULL);
|
||||||
char* imgbuf = (char*)skin_buffer_alloc(buf_size);
|
char* imgbuf = (char*)skin_buffer_alloc(buf_size);
|
||||||
if (!imgbuf)
|
if (!imgbuf)
|
||||||
{
|
{
|
||||||
|
DEBUGF("Not enough skin buffer: need %ld more.\n",
|
||||||
|
buf_size - skin_buffer_freespace());
|
||||||
close(fd);
|
close(fd);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
|
@ -296,6 +296,8 @@ void skin_error_format_message()
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
char text[128];
|
char text[128];
|
||||||
|
if (!error_line_start)
|
||||||
|
return;
|
||||||
char* line_end = strchr(error_line_start, '\n');
|
char* line_end = strchr(error_line_start, '\n');
|
||||||
int len = MIN(line_end - error_line_start, 80);
|
int len = MIN(line_end - error_line_start, 80);
|
||||||
if (!line_end)
|
if (!line_end)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue