Catch up on stories from the past week (and beyond) at the Slashdot story archive

 



Forgot your password?
typodupeerror

Slashdot videos: Now with more Slashdot!

  • View

  • Discuss

  • Share

We've improved Slashdot's video section; now you can view our video interviews, product close-ups and site visits with all the usual Slashdot options to comment, share, etc. No more walled garden! It's a work in progress -- we hope you'll check it out (Learn more about the recent updates).

×
User Journal

Journal: welcome to ourworld...

Journal by kesuki

http://web2.ourworld.com/ow/tracking?source=assoc_widget&user_id=28420792

this is the account ryan recently rediscovered. britney wanted to play with ryan and there was a lot of confusion. ryan also wants the cover page and win/loss and records from his kesuki account on classic battle.net restored and linked to his kesuki@yahoo.com email even though he had been before battle.net had password resets. blizzard are being dicks about it even though restoring one account is so damn easy any demon could do it in their sleep.

User Journal

Journal: In which a certain piece of work on here is thoroughly pegged 5

Journal by smitty_one_each

"In my study of communist societies, I came to the conclusion that the purpose of communist propaganda was not to persuade or convince, not to inform, but to humiliate; and therefore, the less it corresponded to reality the better. When people are forced to remain silent when they are being told the most obvious lies, or even worse when they are forced to repeat the lies themselves, they lose once and for all their sense of probity. To assent to obvious lies is...in some small way to become evil oneself. One's standing to resist anything is thus eroded, and even destroyed. A society of emasculated liars is easy to control. I think if you examine political correctness, it has the same effect and is intended to."

You know who you are, peddler of filth. And if I'm incorrect, I won't know short of Eternity, for this is pretty much what I think of you: a dirty diaper that, despite the best efforts, continues to spew crap in all directions, contaminating everything.
I think you false, diabolical, and unworthy of dialogue. Return to your pit.

User Journal

Journal: Workin' real hard, wishing I could be surprised 26

Journal by smitty_one_each
The supposed Benghazi "investigations" touted by some of the tools in these parts were as useless as suspected.

The timeline isn't an official committee report or publication; it's just an informal summary compiled to help members keep dates straight as they assess the State Department's lack of cooperation. The timeline doesn't include every significant date in the Benghazi investigation, but it does give readers an idea of what Republican investigators have been up against as they've tried to uncover the story of Benghazi. What follows is a fleshed-out version of the timetable--in my words, not the committee's--based on information from committee sources.

As an aside, I'd like to forgive fustakrakich for raping my quotation a couple weeks back. I realize it was a troll, but, as with false accusations from other corners, that sort of thing just destroys my interest in engaging on here.
So there's that.

User Journal

Journal: What is the best android to ubuntu end to end internet encryption solution? 2

Journal by kesuki

my girlfriend was acting strangely and got in trouble. i believe it was due to interception of private cyber messaging. i wish to have something i can explain over the phone to an android user. so basically she needs and app and possible user/login info. i can configure my end but need a walkthrough or other assitance to set up my end of the comms. i need encryption so when it is multicast on the internet it doesn't get spied on because really no one else wants to know what i 37 do with a 21 year old girl anyways so i need encryption for dummies basically for her and anything with a walkthrough for my configuration. i have dyn.com account and an ubuntu server and an ubuntu laptop. she only has an android tablet which i configured for her, but which she will need to set up her encrypted message software.

User Journal

Journal: What do I have to enable now? Fucking DICE. 5

Journal by drinkypoo

Welp, I can use Slashdot in Chrome and not in Firefox, which implies that something I'm blocking in Firefox is preventing the new improved Slashdot from working. What new spyware bullshit do I have to enable to use Slashdot now? Thanks, DICE! You'll run this place the rest of the way into the ground any day now.

User Journal

Journal: Systemd (or, how to make portable software) 10

Journal by phantomfive

In this post, Lennart explains that he doesn't know how to write portable C code. He says:

[Making systemd portable] would turn every second line of systemd into #ifdefs.

The purpose of my post here is to explain how to write portable code, without #ifdefs on every other line. If that happens, you are doing it the hard way.

An easier way is to create an OS independent layer. Call it OSI (since no one is using that acronym anymore, right?). Create a header file that declares all your functions, then create an implementation file for each platform. Every time you find a piece of functionality that is different on different platforms, throw it into that header file.

For example, if you need to take a screenshot, it will be different on every platform you find. In the header file, create a function OSI_Screenshot(). Then in your OSI_Windows.c file, add an implementation for windows. In your OSI_Linux.c, add a screenshot implementation for Linux. In your OSI_OSX.c, add your implementation for OSX. This technique can also work for extremely incompatible platforms, with OSI_printf(), or OSI_malloc(), etc. If you use your compiler correctly, you can compile it without any extra overhead from the function call.

An example of this technique can be found in Android (look at sysdeps.h and sysdeps_win32.c), demonstrating that this technique works. They don't have #ifdefs scattered throughout their code. The Android example is tougher than it needs to be, because Android added the compatibility layer after the code was written. If they had started at the beginning, the code would have been much simpler.

The lack of knowledge (about how to write portable code) in the systemd team is causing them to make bad decisions, because the alternative seems too hard. For example:

I have no plans porting it to other kernels, and I will not merge any such patches........Quite frankly, I'd like to question [cross-platform compatibility]. In the light of GNOME OS I think we need to ask ourselves the question if we do ourselves any good if we continue to support all kinds of kernels that simply cannot keep up with Linux anymore.

Those who don't understand the failures of the past are destined to repeat them. Plenty of vendors try to focus on a single platform, and their work disappeared, to be replaced by something that was cross-platform compatible, and usually better work. The discipline required to keep things portable results in better code (there's a quote from Mythical Man Month that fits here but I'm too lazy to look it up). The Gnome developers understand the importance of portability but that's a story for another post.

User Journal

Journal: Might explain some of the behavior here 23

Journal by smitty_one_each

I have quoted before my old friend Theodore Dalrymple on the purposes of lies in totalitarian societies:

In my study of communist societies, I came to the conclusion that the purpose of communist propaganda was not to persuade or convince, nor to inform, but to humiliate; and therefore, the less it corresponded to reality the better. When people are forced to remain silent when they are being told the most obvious lies, or even worse when they are forced to repeat the lies themselves, they lose once and for all their sense of probity. To assent to obvious lies is to co-operate with evil, and in some small way to become evil oneself. One's standing to resist anything is thus eroded, and even destroyed. A society of emasculated liars is easy to control.

This has a ring of truth to it with respect to Slashdot. I've been on the receiving end of repeated accusations used like bludgeons to the point there are some people on here to whom I just ain't got jack to say beyond: "Lord bless your heart".
Which is not to whine about it. This is Slashdot; let the incontinent go elsewhere.
Rather, I'm yawning.

User Journal

Journal: And you thought Twitter useless 11

Journal by smitty_one_each
User Journal

Journal: Nebbishes Yearning for Truth (NYT) 26

Journal by smitty_one_each
Pravda on the Hudson decided to un-frack itself with its Gail Collins hit piece.
I don't really care if Slashdot's favorite dirty diaper un-soils himself on the subject as in this JE.
It would be fine if he manned up and repented of being a total crapflooder; I'd enjoy adult conversations with him, as he seems an intelligent person. But then, we're talking about a dedicated bile spewer here. The sort that yields to nothing less than full-on Divine Intervention. So let me pray for that.
User Journal

Journal: Systemd's solution to large init scripts 1

Journal by phantomfive

(Note: When you write code, you're making a UI for programmers. Learn to do it well.)

Below you can see a traditional unix init script. It's long, but if you're familiar with shell-script you can figure out what is going on. There is a lot of redundancy here, most init scripts have a switch that runs an option based on the first command-line parameter, for example. One solution is to put common code in a function, but Poettering decided to use config files.

Let's examine the general tradeoff between putting code in a function, and using config files (a form of declarative programming). Config files are fine as long as there aren't too many special cases. If there are too many special cases, you end up with so many options and keywords that it would have been easier to just use a scripting language.

The good side is systemd saves a lot of typing. Way down at the bottom, is a unit file for the same init script. It's clearly shorter, and easier to type.

The bad side is it has arcane keywords which are are not discoverable merely by looking at the file. This is a pattern that repeats itself over and over in systemd, things are easier if you know how to do them, but the system itself is inscrutable without arcane knowledge.

Ideal systems fulfill the requirements while making it easy for those who want to dig deeper. The system opens like the petals of a rose.

#!/bin/bash
# Starts the abrt daemon
#
# chkconfig: 35 82 16
# description: Daemon to detect crashing apps
# processname: abrtd
### BEGIN INIT INFO
# Provides: abrt
# Required-Start: $syslog $local_fs
# Required-Stop: $syslog $local_fs
# Default-Stop: 0 1 2 6
# Default-Start: 3 5
# Short-Description: start and stop abrt daemon
# Description: Listen to and dispatch crash events
### END INIT INFO
 
# Source function library.
. /etc/rc.d/init.d/functions
ABRT_BIN="/usr/sbin/abrtd"
LOCK="/var/lock/subsys/abrtd"
OLD_LOCK="/var/lock/subsys/abrt"
RETVAL=0
 
#
# Set these variables if you are behind proxy
#
#export http_proxy=
#export https_proxy=
 
#
# See how we were called.
#
 
check() {
    # Check that we're a privileged user
    [ "`id -u`" = 0 ] || exit 4
 
    # Check if abrt is executable
    test -x $ABRT_BIN || exit 5
}
 
start() {
 
    check
 
    # Check if it is already running
    if [ ! -f $LOCK ] && [ ! -f $OLD_LOCK ]; then
        echo -n $"Starting abrt daemon: "
        daemon $ABRT_BIN
        RETVAL=$?
        [ $RETVAL -eq 0 ] && touch $LOCK
        echo
    fi
    return $RETVAL
}
 
stop() {
 
    check
 
    echo -n $"Stopping abrt daemon: "
    killproc $ABRT_BIN
    RETVAL=$?
    [ $RETVAL -eq 0 ] && rm -f $LOCK
    [ $RETVAL -eq 0 ] && rm -f $OLD_LOCK
    echo
    return $RETVAL
}
 
restart() {
    stop
    start
}
 
reload() {
    restart
}
 
case "$1" in
start)
    start
;;
stop)
    stop
;;
reload)
    reload
;;
force-reload)
    echo "$0: Unimplemented feature."
    RETVAL=3
;;
restart)
    restart
;;
condrestart)
    if [ -f $LOCK ]; then
        restart
    fi
    # update from older version
    if [ -f $OLD_LOCK ]; then
        restart
    fi
;;
status)
    status abrtd
    RETVAL=$?
;;
*)
    echo $"Usage: $0 {start|stop|status|restart|condrestart|reload|force-reload}"
    RETVAL=2
esac
 
exit $RETVAL

-----------------------------------------------------------------------------------------

[Unit]
Description=Daemon to detect crashing apps
After=syslog.target
 
[Service]
ExecStart=/usr/sbin/abrtd
Type=forking
 
[Install]
WantedBy=multi-user.target

Reference to the examples.

If you can't understand it, it is intuitively obvious.

Working...