Remove All Ads from XDA

[Q] property_set and property_get usage

2 posts
Thanks Meter: 0
By arTsmarT, Junior Member on 18th June 2014, 04:12 PM
Post Reply Email Thread
I'm trying to set and retrieve properties in my native code using property_get and property_set but it doesn't seem to be working. I tried adding debug logs but they don't show up too. I'm not sure if I'm doing it all wrong but here's what I did,
I have
in a function in one file and

char value[PROPERTY_VALUE_MAX]; 
in another file.

I modified property_service.c to this

/* White list of permissions for setting property services. */
struct {
    const char *prefix;
    unsigned int uid;
    unsigned int gid;
} property_perms[] = {
    { "net.rmnet0.",      AID_RADIO,    0 },
    { "service.adb.tcp.port", AID_SHELL,    0 },
    { "persist.sys.",     AID_SYSTEM,   0 },
    { "persist.service.", AID_SYSTEM,   0 },
    { "", AID_SYSTEM,   0 },
    { "dm.", AID_SYSTEM,  0},
    { NULL, 0, 0 }
Am I missing anything here?
Post Reply Subscribe to Thread

Guest Quick Reply (no urls or BBcode)
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes