summaryrefslogtreecommitdiffstats
path: root/xrdp/xrdp_cache.c
diff options
context:
space:
mode:
authorjsorg71 <jsorg71>2005-02-25 03:15:06 +0000
committerjsorg71 <jsorg71>2005-02-25 03:15:06 +0000
commitdda1ae712c51dc84b17f439c7b6009ef0a266692 (patch)
tree8b3e6a15ce5ea5431143c1dca8f29b720aa225e6 /xrdp/xrdp_cache.c
parent16b9bacf7572dae4092a9c347146af3672ea512e (diff)
downloadxrdp-proprietary-dda1ae712c51dc84b17f439c7b6009ef0a266692.tar.gz
xrdp-proprietary-dda1ae712c51dc84b17f439c7b6009ef0a266692.zip
bitmap cache change
Diffstat (limited to 'xrdp/xrdp_cache.c')
-rw-r--r--xrdp/xrdp_cache.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/xrdp/xrdp_cache.c b/xrdp/xrdp_cache.c
index 7c315526..e3c73ecd 100644
--- a/xrdp/xrdp_cache.c
+++ b/xrdp/xrdp_cache.c
@@ -94,7 +94,7 @@ int xrdp_cache_add_bitmap(struct xrdp_cache* self, struct xrdp_bitmap* bitmap)
bmp_size = (bitmap->width + e) * bitmap->height * Bpp;
self->bitmap_stamp++;
/* look for match */
- if (bmp_size < self->cache1_size)
+ if (bmp_size <= self->cache1_size)
{
i = 0;
for (j = 0; j < self->cache1_entries; j++)
@@ -113,7 +113,7 @@ int xrdp_cache_add_bitmap(struct xrdp_cache* self, struct xrdp_bitmap* bitmap)
}
}
}
- else if (bmp_size < self->cache2_size)
+ else if (bmp_size <= self->cache2_size)
{
i = 1;
for (j = 0; j < self->cache2_entries; j++)
@@ -132,7 +132,7 @@ int xrdp_cache_add_bitmap(struct xrdp_cache* self, struct xrdp_bitmap* bitmap)
}
}
}
- else if (bmp_size < self->cache3_size)
+ else if (bmp_size <= self->cache3_size)
{
i = 2;
for (j = 0; j < self->cache3_entries; j++)
@@ -153,13 +153,13 @@ int xrdp_cache_add_bitmap(struct xrdp_cache* self, struct xrdp_bitmap* bitmap)
}
else
{
- g_printf("error in xrdp_cache_add_bitmap, too big\n\r");
+ g_printf("error in xrdp_cache_add_bitmap, too big(%d)\n\r", bmp_size);
}
/* look for oldest */
cache_id = 0;
cache_idx = 0;
oldest = 0x7fffffff;
- if (bmp_size < self->cache1_size)
+ if (bmp_size <= self->cache1_size)
{
i = 0;
for (j = 0; j < self->cache1_entries; j++)
@@ -172,7 +172,7 @@ int xrdp_cache_add_bitmap(struct xrdp_cache* self, struct xrdp_bitmap* bitmap)
}
}
}
- else if (bmp_size < self->cache2_size)
+ else if (bmp_size <= self->cache2_size)
{
i = 1;
for (j = 0; j < self->cache2_entries; j++)
@@ -185,7 +185,7 @@ int xrdp_cache_add_bitmap(struct xrdp_cache* self, struct xrdp_bitmap* bitmap)
}
}
}
- else if (bmp_size < self->cache3_size)
+ else if (bmp_size <= self->cache3_size)
{
i = 2;
for (j = 0; j < self->cache3_entries; j++)