03-07-2009
Quote:
Originally Posted by
Corona688
I'd suggest assigning members of fl instead of giving fl a definition block. It's possible the layout of a flock structure has members before the standard ones on osx.
Hi,
You were right. I did not notice it earlier, but when I checked the manpage for fcntl, the struct members were in different order in mac than in linux.
I wonder why they would do that though..
Thanks.
10 More Discussions You Might Find Interesting
1. Programming
hi, I need to know how to lock a file. I used the following code, but after executing the program the file 'write.txt' remined empty, and I have no idea why.Maybe I'm not using the corresponding syntax for blocking a file. But I deleted then the blocking part and the problem persisted.
see to... (2 Replies)
Discussion started by: atticus
2 Replies
2. Shell Programming and Scripting
I'm in the same boat as Barbus - same exercis (https://www.unix.com/shell-programming-scripting/43609-processes-users.html)
The following script works on a solaris server I have access to. It doesn't however, work on the companies Linux machine. Any idea what's up? I have very little shell... (0 Replies)
Discussion started by: Silverhood
0 Replies
3. Programming
I have very simple client - server setup, where client connects, exchanges some messages with the server and then closes socket and exits. Everythink works OK, except when I am trying to change socket to be non-blocking AND the shell happens to be plain old Bourne. It runs no problem under ksh or... (3 Replies)
Discussion started by: migurus
3 Replies
4. Shell Programming and Scripting
Hello,
I found this command works on Linux:
$ echo `uptime` | awk -F "load average: " '{ print $2 }'
1.60, 1.53, 1.46
but got error on Solaris:
$ echo `uptime` | awk -F "load average: " '{ print $2 }'
awk: syntax error near line 1
awk: bailing out near line 1
$ which awk... (2 Replies)
Discussion started by: seafan
2 Replies
5. Shell Programming and Scripting
Hello
I have a Perl script that works on non-darwin Mac OS X environments and I think I have narrowed down the issue to a file locking problem.
In other linux environments, the flock struct is defined differently. I have adjusted this via the reference for Mac OS X fcntl(2) man page. The... (4 Replies)
Discussion started by: flagman5
4 Replies
6. Shell Programming and Scripting
Hi, I have a question.
I define a function using sed command:
replace()
{
searchterm=$1
replaceterm=$2
sed -e "s/$searchterm/$replaceterm/ig" $3 > $WORK'tempfile.tmp'
mv $WORK'tempfile.tmp' $3
}
Then I call
replace 'test = 0' 'test = 1' $myfileThis code works well in... (1 Reply)
Discussion started by: Dark2Bright
1 Replies
7. Shell Programming and Scripting
Hi, I have a question.
I define a function using sed command:
replace()
{
searchterm=$1
replaceterm=$2
sed -e "s/$searchterm/$replaceterm/ig" $3 > $WORK'tempfile.tmp'
mv $WORK'tempfile.tmp' $3
}
Then I call
replace 'test = 0' 'test = 1' $myfile
This code... (1 Reply)
Discussion started by: Dark2Bright
1 Replies
8. Linux
Good evening, friends
I'm learning with a book: Programming Linux by Kurt Wall (Prentice Hall)
The code below could run in two windows (./lockit /tmp/foo in both for example). There is not problem with the read block (first byte) but when one, apply the write block while in the other is... (1 Reply)
Discussion started by: joe_cosmo
1 Replies
9. Shell Programming and Scripting
Hello,
I have a ksh script that uses code below. For some reason it works under linux but fails in unix. Any idea why?
if ]; then ...
Thanks (9 Replies)
Discussion started by: rdogadin
9 Replies
10. Hardware
Hello folks,
I pretend acquire this hardware:
1-Motherboard Asus Skt1151 - H110M-A/M.2 (https://www.asus.com/pt/Motherboards...cifications/);
2-Intel i5 6400 2.7Ghz QuadCore Skt1151;
or
2-Intel i5 6500 3.2Ghz QuadCore Skt1151;
3-Dimm 8GB DDR4 Kingston CL15 2133Mhz;
Obvious I pretend... (1 Reply)
Discussion started by: enodev
1 Replies
LEARN ABOUT SUSE
list_members
LIST_MEMBERS(8) System Manager's Manual LIST_MEMBERS(8)
NAME
list_members - List all the members of a Mailman list
SYNOPSIS
list_members [-o file] [-r] [-d] [-p] [-h] listname
OPTIONS
-o file, --output file
Write output to specified file instead of standard out.
-r, --regular
Print just the regular (non-digest) members.
-d [kind], --digest[=kind]
Print just the digest members. Optional argument can be "mime" or "plain" which prints just the digest members receiving that kind
of digest.
--nomail[=why], -n [why]
Print the members that have delivery disabled. Optional argument can be "byadmin", "byuser", "bybounce", or "unknown" which prints
just the users who have delivery disabled for that reason. It can also be "enabled" which prints just those member for whom deliv-
ery is enabled.
-f, --fullnames
Include the full names in the output.
-p, --preserve
Output member addresses case preserved the way they were added to the list. Otherwise, addresses are printed in all lowercase.
-i, --invalid
Print only the addresses in the membership list that are invalid. Ignores -r, -d, -n.
-u, --unicode
Print addresses which are stored as Unicode objects instead of normal string objects. Ignores -r, -d, -n.
-h, --help
Print a small help text and exit
listname is the name of the mailing list to use.
NOTES
Note that if neither -r or -d is supplied, both regular members are printed first, followed by digest members, but no indication is given
as to address status.
AUTHOR
Author of Mailman is the Mailman Cabal, see http://www.list.org/ for information. This manpage is written by Tollef Fog Heen
<tfheen@debian.org> for Debian GNU/Linux.
SEE ALSO
Mailman documentation on http://www.list.org/ and in /usr/share/doc/mailman.
2004-10-17 LIST_MEMBERS(8)