Changeset 5e3e42c7 in mainline
- Timestamp:
 - 2020-06-16T10:52:38Z (5 years ago)
 - Branches:
 - lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
 - Children:
 - 94f3747
 - Parents:
 - 3e640e5
 - git-author:
 - Jiri Svoboda <jiri@…> (2020-06-15 17:31:57)
 - git-committer:
 - Jiri Svoboda <jiri@…> (2020-06-16 10:52:38)
 - Location:
 - uspace/lib/ipcgfx
 - Files:
 - 
      
- 2 edited
 
- 
          
  private/server.h (modified) (2 diffs)
 - 
          
  src/server.c (modified) (3 diffs)
 
 
Legend:
- Unmodified
 - Added
 - Removed
 
- 
      
uspace/lib/ipcgfx/private/server.h
r3e640e5 r5e3e42c7 43 43 #include <gfx/context.h> 44 44 #include <gfx/coord.h> 45 #include <stdbool.h> 45 46 46 47 /** Server-side of IPC GC connection. … … 65 66 /** Bitmap ID */ 66 67 sysarg_t bmp_id; 68 /** @c true if we allocated the pixels */ 69 bool myalloc; 70 /** Pixels of the bitmap */ 71 void *pixels; 67 72 } ipc_gc_srv_bitmap_t; 68 73  - 
      
uspace/lib/ipcgfx/src/server.c
r3e640e5 r5e3e42c7 164 164 (unsigned) srvbmp->bmp_id); 165 165 166 /* We created the memory area by sharing it in */ 167 srvbmp->myalloc = true; 168 srvbmp->pixels = pixels; 169 166 170 async_answer_1(icall, EOK, srvbmp->bmp_id); 167 171 } … … 246 250 srvbmp->bmp = bitmap; 247 251 srvbmp->bmp_id = srvgc->next_bmp_id++; 252 253 /* Area allocated by backing GC, we just shared it out */ 254 srvbmp->myalloc = false; 255 srvbmp->pixels = alloc.pixels; // Not really needed 256 248 257 printf("gc_bitmap_create_doutput_srv: storing bmp_id=%u\n", 249 258 (unsigned) srvbmp->bmp_id); … … 271 280 return; 272 281 } 282 283 if (bitmap->myalloc) 284 as_area_destroy(bitmap->pixels); 273 285 274 286 list_remove(&bitmap->lbitmaps);  
  Note:
 See   TracChangeset
 for help on using the changeset viewer.
  