return width;
}
-static int integer_width(unsigned KLONG number)
+static int integer_width(unsigned long number)
{
int result;
static char mapbuf[1024];
-static unsigned KLONG range_low;
-static unsigned KLONG range_high = ~0ull;
+static unsigned long range_low;
+static unsigned long range_high = ~0ul;
static int c_option;
static int C_option;
char perms[32];
/* to clean up unprintables */
char *tmp;
- unsigned KLONG start, end;
+ unsigned long start, end;
unsigned long long file_offset, inode;
unsigned dev_major, dev_minor;
sscanf(mapbuf_b, "%" KLF "x-%" KLF "x %31s %llx %x:%x %llu", &start,
return;
}
-static char *mapping_name(struct pids_stack *p, unsigned KLONG addr,
- unsigned KLONG len, const char *mapbuf_b,
+static char *mapping_name(struct pids_stack *p, unsigned long addr,
+ unsigned long len, const char *mapbuf_b,
unsigned showpath, unsigned dev_major,
unsigned dev_minor, unsigned long long inode)
{
}
cp = _(" [ anon ]");
- if (PROCPS_PIDS_VAL(start_stack, addr, p) >= (void*)addr
- && (PROCPS_PIDS_VAL(start_stack, addr, p) <= (void*)addr + len))
+ if (PROCPS_PIDS_VAL(start_stack, ul_int, p) >= addr
+ && (PROCPS_PIDS_VAL(start_stack, ul_int, p) <= addr + len))
cp = _(" [ stack ]");
return cp;
}
struct listnode {
char description[DETAIL_LENGTH];
char value_str[NUM_LENGTH];
- unsigned KLONG value;
- unsigned KLONG total;
+ unsigned long value;
+ unsigned long total;
int max_width;
struct listnode *next;
};
unsigned long total_shared = 0ul;
unsigned long total_private_readonly = 0ul;
unsigned long total_private_writeable = 0ul;
- unsigned KLONG diff = 0;
+ unsigned long diff = 0;
const char *cp2 = NULL;
unsigned long long rss = 0ull;
unsigned long long private_dirty = 0ull;
if (x_option) {
maxw1 = 16;
- if (sizeof(KLONG) == 4) maxw1 = 8;
+ if (sizeof(long) == 4) maxw1 = 8;
maxw2 = maxw3 = maxw4 = 7;
maxw5 = 5;
if (!q_option) {
if (d_option) {
maxw1 = 16;
- if (sizeof(KLONG) == 4) maxw1 = 8;
+ if (sizeof(long) == 4) maxw1 = 8;
maxw2 = 7;
maxw3 = 5;
maxw4 = 16;
char perms[32];
/* to clean up unprintables */
char *tmp;
- unsigned KLONG end, start = 0;;
+ unsigned long end, start = 0;;
unsigned long long file_offset, inode;
unsigned dev_major, dev_minor;
unsigned long long smap_value;
const char *cp =
mapping_name(p, start, diff, mapbuf, map_desc_showpath, dev_major,
dev_minor, inode);
- printf((sizeof(KLONG) == 8)
+ printf((sizeof(long) == 8)
? "%016" KLF "x %6luK %s %s\n"
: "%08lx %6luK %s %s\n",
start, (unsigned long)(diff >> 10), perms, cp);
fclose(fp);
if (!q_option) {
if (x_option) {
- if (sizeof(KLONG) == 4)
+ if (sizeof(long) == 4)
justify_print("--------", maxw1, 0);
else
justify_print("----------------", maxw1, 0);
total_private_writeable >> 10, total_shared >> 10);
}
if (!x_option && !d_option) {
- if (sizeof(KLONG) == 8)
+ if (sizeof(long) == 8)
/* Translation Hint: keep total string length
* as 24 characters. Adjust %16 if needed*/
printf(_(" total %16ldK\n"),