Changeset 70e2b2d in mainline for uspace/app/uptime/uptime.c


Ignore:
Timestamp:
2010-04-18T10:23:15Z (14 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
c3d4bb45
Parents:
da98918
Message:

avoid costly allocation and generation of data when it is actually not necessary

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/app/uptime/uptime.c

    rda98918 r70e2b2d  
    3939#include <sys/time.h>
    4040#include <inttypes.h>
     41#include <malloc.h>
    4142
    4243#define NAME  "uptime"
     
    7475                        print_load_fragment(load[i], 2);
    7576                }
     77               
     78                free(load);
    7679        }
    7780       
Note: See TracChangeset for help on using the changeset viewer.