Hi all. I am trying to use restricted pointers to allow the gcc compiler optimize the code, but I have not been able to make it work so far. I am testing with this code:
The gcc-4.2 compiler does not even complaints for the last part with the -O3 and -std=c99 options. Dues someone knows how to make restricted pointers work? Thanks in advance.
Below is the program i tried to execute......
main()
{
static int a = {0,1,2,3,4};
static int *p = {a, a+1, a+2, a+3, a+4};
printf (“\n %u %u %d”, p, *p, *(*p) );
}
This works, but i wanted to know why both a and *p are declared as "static". If we dont declare a as static... (2 Replies)
A few of the other employees here need to learn "vi" in order to use crontab to schedule / unschedule jobs on one of our production servers. I tried to set up a login on one of my Linux boxes for them to use "vimtutor", but scrapped it and decided to try for something more secure, since there are... (1 Reply)
I am having trouble getting restricted SAM to work by allocating Privileges to a "group". I can make it work by allocaing to the userid's, but would preferre to use the "group" option.
Running B.11.11
Tried the following....
1) Created a user group in /etc/group first
2) Used the... (1 Reply)
Hi I mash with pointers in C. I solve this problem about 5 hours and I don't know how I should continue.
void InsertFirst (tList *L, int val) {
tElemPtr new;
if((new = malloc(sizeof(tElemPtr))) == NULL) Error();
new->data = val;
new->ptr = L->frst;
L->frst = new;... (2 Replies)
I have a task to create a new id that going to used by vendor. The ID profiles are:
1)The ID to be created is MUST be restricted sharing.
2)create for their own user account
3)unable to read/navigate/view other directories
4)unable to write to other directories
able to create their own... (3 Replies)
I have a special character called ô. When it is declared as a character variable its showing it can be printed. But when it is declared as a character pointer variable its showing it cannot be printed. I am just wondering why its happening like this..
c1 = '@';
c2 = 'ô';
char *fp;
fp="XXô";
if... (1 Reply)
Hello
I have a user with a Restricted Shell on a Aix 5.3. My question is about if I can add one more path on the home directory.
I mean the user have in his home directory. for example /test/my_application/logs but I need that this user can view another log that is on another path, if this... (1 Reply)
Hello everyone
I need to create a restricted user or a special user. Here is what I need.
I have this path
next to profiles I have server1, server2, server3.......
The user that I have to create I need that he can move between server1. server2, server3 because in every one have logs... (1 Reply)