Humor Random Comments Thread

jedidia

shoemaker without legs
Addon Developer
Joined
Mar 19, 2008
Messages
10,882
Reaction score
2,133
Points
203
Location
between the planets
Kind of very specific instead of random, but really not worth its own thread. I just realised that I have a gap in my C++ when it comes to references. Consider this:

Code:
void myfunc(int &output)
{
    int i = 0;
    output = i;
}

Is output then pointing to i (which is no longer on the stack when the function exits), or has the value of i been written into the memory output was pointing to? I would assume the later, since there's no dereferenciation of i, but I have to admitt that I'm not 100% sure...
 

Blake

Addon Developer
Addon Developer
Joined
Mar 9, 2009
Messages
235
Reaction score
123
Points
58
Location
Lehi, Utah
Kind of very specific instead of random, but really not worth its own thread. I just realised that I have a gap in my C++ when it comes to references. Consider this:

Code:
void myfunc(int &output)
{
    int i = 0;
    output = i;
}

Is output then pointing to i (which is no longer on the stack when the function exits), or has the value of i been written into the memory output was pointing to? I would assume the later, since there's no dereferenciation of i, but I have to admitt that I'm not 100% sure...

When in doubt, the debugger is your friend. :thumbup:

Here's what your variables look like before assigning to output:

Code:
+		&output	0x00fcfd98 {20}	int *
+		&i	0x00fcfcb4 {0}	int *

and after:

Code:
+		&output	0x00fcfd98 {0}	int *
+		&i	0x00fcfcb4 {0}	int *

output takes the value of i, not its address.
 

RisingFury

OBSP developer
Addon Developer
Joined
Aug 15, 2008
Messages
6,427
Reaction score
492
Points
173
Location
Among bits and Bytes...
This:

Code:
void myfunc(int &output)
{
    int i = 0;
    output = i;
}

is effectively the same as:

Code:
void myfunc(int *output)
{
    int i = 0;
    (*output) = i;
}


Essentially the reference does what a pointer does after you dereference it, but it does it "under the hood". In a function it pretends to be a local variable, but one that actually affects the variable outside of the scope of the function.
 

steph

Well-known member
Joined
Mar 22, 2008
Messages
1,394
Reaction score
715
Points
113
Location
Vendee, France
The good part about living in an oceanic climate: there are no storms.... The bad part : the same
 

Urwumpe

Not funny anymore
Addon Developer
Donator
Joined
Feb 6, 2008
Messages
37,627
Reaction score
2,345
Points
203
Location
Wolfsburg
Preferred Pronouns
Sire
There you are spending a full weekend in a small hut in the Harz mountains, far away from Internet and when you return, you read something about a coup in a distant country.
 

steph

Well-known member
Joined
Mar 22, 2008
Messages
1,394
Reaction score
715
Points
113
Location
Vendee, France
There you are spending a full weekend in a small hut in the Harz mountains, far away from Internet and when you return, you read something about a coup in a distant country.

Well, at least you don't hear about nuclear war between India and Pakistan :lol:
 

Urwumpe

Not funny anymore
Addon Developer
Donator
Joined
Feb 6, 2008
Messages
37,627
Reaction score
2,345
Points
203
Location
Wolfsburg
Preferred Pronouns
Sire
Well, at least you don't hear about nuclear war between India and Pakistan :lol:

Seriously, I couldn't have been more surprised. We had a great time, with friends from my tabletop club and their families.

Sadly, the water supply was broken, taking a shower was nearly impossible.
 

Urwumpe

Not funny anymore
Addon Developer
Donator
Joined
Feb 6, 2008
Messages
37,627
Reaction score
2,345
Points
203
Location
Wolfsburg
Preferred Pronouns
Sire
Some 17 year old from Afghanistan tried to kill people in a German regional train with an axe and a knife, he badly injured 4 tourists from Hong Kong, two of them are still in a life threatening state. Looks like he wanted to be a daesh drone, he had painted an islamistic flag himself in his room, but that is also all that really exists now about his daesh links. He had been living in Germany for two years now, first in a catholic home for young apprentices, later in a foster family.

He was shot by a SWAT unit, which was by plain chance near the place where the train stopped.
 

jedidia

shoemaker without legs
Addon Developer
Joined
Mar 19, 2008
Messages
10,882
Reaction score
2,133
Points
203
Location
between the planets
I kind of would expect a SWAT team to be able to disable a man armed with a melee weapon without killing him. Then again, in a train there might be a significant chance to hit a bystander if you don't aim center...
 

Urwumpe

Not funny anymore
Addon Developer
Donator
Joined
Feb 6, 2008
Messages
37,627
Reaction score
2,345
Points
203
Location
Wolfsburg
Preferred Pronouns
Sire
I kind of would expect a SWAT team to be able to disable a man armed with a melee weapon without killing him. Then again, in a train there might be a significant chance to hit a bystander if you don't aim center...

Well, it was night and he was charging towards the SWAT team. Also the team had only minutes to prepare for the mission. I can understand why the police resorted to play safe there - compared to other incidents in Bavaria, they handled it very professional.
 

Linguofreak

Well-known member
Joined
May 10, 2008
Messages
5,034
Reaction score
1,273
Points
188
Location
Dallas, TX
Random question: Does anyone have any pointers on getting Qemu (managed with virt-manager, specifically) to waste less guest-physical address space on MMIO on 32-bit guests? As seen by Windows, it's eating a full GiB. On physical hardware the amount of physical address space under 4 GiB you lose is going to be fairly set in stone for a given model, but I figure on a VM like Qemu you might be able to configure a fair bit of the wastage away.
 

Notebook

Addon Developer
Addon Developer
News Reporter
Donator
Joined
Nov 20, 2007
Messages
11,816
Reaction score
641
Points
188
Last edited:

Urwumpe

Not funny anymore
Addon Developer
Donator
Joined
Feb 6, 2008
Messages
37,627
Reaction score
2,345
Points
203
Location
Wolfsburg
Preferred Pronouns
Sire
There is a shooting in a shopping mall in Munich (Olympia-Einkaufszentrum), a single male shooter armed with a pistol has been recorded on smartphone videos and is still on the run. Injuries and casualties are still unknown. The shooting seems to have started in a McDonalds restaurant.

Lots of heavily armed police is on site, police is recommending to stay away from the location.

Earlier reports of other shootings in different places of Munich turned out to be wrong.

---------- Post added at 07:41 PM ---------- Previous post was at 07:37 PM ----------

A second shooting at the Stachus plaza and a panic at the nearby Marienplatz is confirmed now by unreliable panicking RTL television, police is also deploying there now.

The citizens are recommended to stay at home and avoid public places.

---------- Post added at 07:44 PM ---------- Previous post was at 07:41 PM ----------

And again, Stachus was a false alert, the police confirmed now on their twitter account. The subway system of Munich is shutdown and the stations are evacuated.

---------- Post added at 07:49 PM ---------- Previous post was at 07:44 PM ----------

And the police now calls out to the population to stop streaming videos and pictures of the police operations, please don't help the shooters.

(The first time the police is talking about more than one shooter)

There seems to be multiple deaths now.

---------- Post added at 08:19 PM ---------- Previous post was at 07:49 PM ----------

Witnesses report three different shooters, all still on the run.

---------- Post added at 08:27 PM ---------- Previous post was at 08:19 PM ----------

And multiple witnesses report it to be Neonazi shooters, on the fifth anniversary of the Oslo killings.

---------- Post added at 09:58 PM ---------- Previous post was at 08:27 PM ----------

Right now, its six casualties, one person died in hospital from its injuries. There are an unknown number of injuries.

Unconfirmed news by a private news outlet report that one attacker killed himself some minutes ago when surrounded by the police near the shopping mall but that was not confirmed by the police (EDIT: But this is now also reported by multiple local newspapers now, so it seems to be somewhat reliable information).

---------- Post added at 10:40 PM ---------- Previous post was at 09:58 PM ----------

Police confirmed that they have found a male corpse in the mall which is a suspected attacker. Death toll increased to nine (eight plus the possible attacker).

---------- Post added 07-23-16 at 12:06 AM ---------- Previous post was 07-22-16 at 10:40 PM ----------

The dead person which was found in a garden in the Olympic Village is found wearing the same red backpack as the shooter which started the spree killing in the McDonalds restaurant. Police is still not approaching the corpse, waiting for a robot to check if the backpack is booby-trapped.

More smartphone videos appear suggesting a nationalist German background of the attackers.

---------- Post added at 12:42 AM ---------- Previous post was at 12:06 AM ----------

Funnily, while all evidence starts to suggest some weird nationalist background (You can also hear the words "psychatry" and "hartz 4" (german welfare law) in the shouting of the attacker), CNN seems to have found the only "eye witness" claiming an Islamist background.

---------- Post added at 01:19 AM ---------- Previous post was at 12:42 AM ----------

The police operation seems to end now slowly, buses and subways are driving again.

Up to 100 people had been direct eyewitnesses of the attack, 21 are wounded.

---------- Post added at 01:35 PM ---------- Previous post was at 01:19 AM ----------

Now it seems to really be a spree killing. The attacker was a 18 year old male by the name of David S., with German and Iranian nationality, who was born and grew up in Munich and used the past days researching other spree killings on his computer. He had been in psychiatric treatment for some time before.

His nine victims are mostly from 13 years to 20 years, two girls and six boys, only one 45 year old woman as exception there.

More precise: Two 13 year old, three 14 year old, one 17 year old, one 19 year old, one 20 year old, and one 45 year old victim. Three victims had been of Turkish descent.




---------- Post added at 01:48 PM ---------- Previous post was at 01:35 PM ----------

The 9mm Glock pistol that he used in the killing is clearly illegal, the serial number was removed. He had 300 rounds ammo left in his backpack when his dead corpse was found.
 
Last edited:

jedidia

shoemaker without legs
Addon Developer
Joined
Mar 19, 2008
Messages
10,882
Reaction score
2,133
Points
203
Location
between the planets
omg, I never thought I'd be writing unit tests for my Orbiter add-ons, but things are getting a tad complex... :blink:
 

Notebook

Addon Developer
Addon Developer
News Reporter
Donator
Joined
Nov 20, 2007
Messages
11,816
Reaction score
641
Points
188
http://www.bbc.co.uk/programmes/p041fdj2

Inside a former nuclear missile base

The Titan Missile Museum is a decommissioned intercontinental ballistic missile complex in Arizona, USA.

The missile complex was capable of delivering a nine-megaton nuclear warhead to targets more than 10,000km (6,200 miles) away.

Director of the museum and former crew commander in the 1980s, Yvonne Morris, tells the BBC Travel Show's Rajan Datar why it is important that people are allowed visit the site.

Release date:
19 July 2016
Clip from BBC travel show, don't know if it will get out the UK.

N.
 

Urwumpe

Not funny anymore
Addon Developer
Donator
Joined
Feb 6, 2008
Messages
37,627
Reaction score
2,345
Points
203
Location
Wolfsburg
Preferred Pronouns
Sire
omg, I never thought I'd be writing unit tests for my Orbiter add-ons, but things are getting a tad complex... :blink:

Welcome to the light side of the force. :thumbup:
 

Andy44

owner: Oil Creek Astronautix
Addon Developer
Joined
Nov 22, 2007
Messages
7,620
Reaction score
7
Points
113
Location
In the Mid-Atlantic states
It's like 100 degF in the DC area this weekend, and as the morning progresses the humidity is getting stupid high as well. I know a lot of people hate winter, but I love it. I'll take wearing a nice wool coat over sweating and mosquitos any day. Right now you can't walk from your front door to your car without feeling gross.
 
Top