text stringlengths 0 30.5k | title stringclasses 1
value | embeddings listlengths 768 768 |
|---|---|---|
alone, but I really don't understand why). However, this approach requires a lot of boiler-plate code, and Tomcat is a huge memory hog on our server.
I'm looking for a better way to do this. One way I'm considering is to make the MySQL database publicly accessible, re-writing the JDBC based code as stored procedures, ... | [
0.10558248311281204,
0.36930331587791443,
0.09921804070472717,
0.13112865388393402,
-0.073841392993927,
-0.3709515929222107,
0.39781978726387024,
-0.09803517907857895,
-0.10469068586826324,
-0.37221357226371765,
-0.08374561369419098,
0.6896661520004272,
-0.3171882927417755,
0.3638620674610... | |
which performs select statements on a table, but also deny arbitrary select statements on that same table?
Any other ideas are welcome, as are thoughts and or sugguestions on the stored procedure solution.
Thank you!
The [AWK book](https://archive.org/details/pdfy-MgN0H1joIoDVoIC7) is full of great examples. They use... | [
0.2765241861343384,
0.2777799963951111,
-0.2839379608631134,
0.05816701427102089,
-0.10284791141748428,
-0.08301088213920593,
0.35902926325798035,
-0.5242993235588074,
-0.27440881729125977,
-0.03263956308364868,
-0.09069527685642242,
0.15308241546154022,
-0.09189683943986893,
-0.0324248336... | |
I have an Eclipse RCP application that displays a lot (10k+) of small images next to each other, like a film strip. For each image, I am using a SWT `Image` object. This uses an excessive amount of memory and resources. I am looking for a more efficient way. I thought of taking all of these images and concatenating the... | [
0.6687681078910828,
-0.08708968758583069,
0.32647207379341125,
0.16389469802379608,
-0.3896731734275818,
0.07530508935451508,
-0.18690355122089386,
-0.17962516844272614,
-0.10066323727369308,
-0.7575263381004333,
0.25795695185661316,
0.4397847056388855,
-0.10416296869516373,
0.026780145242... | |
tiling or mosaic functionality to create one image from a group of images, but found nothing.
Any ideas how I can display thousands of small images next to each other efficiently? Please note that once the images are displayed, they are not manipulated, so this is a one-time cost.
You can draw directly on the GC (grap... | [
0.8242856860160828,
-0.08152488619089127,
0.24096013605594635,
0.15042372047901154,
-0.11132638901472092,
0.17953592538833618,
-0.2017136961221695,
0.022597143426537514,
-0.341187059879303,
-1.1542630195617676,
0.5022709965705872,
0.13614165782928467,
-0.365990549325943,
0.1004122793674469... | |
final List<Image> images;
final Image bigImage = new Image(Display.getCurrent(), combinedWidth, height);
final GC gc = new GC(bigImage);
//loop thru all the images while increasing x as necessary:
int x = 0;
int y = 0;
for (Image curImage : images) {
gc.drawIm... | [
0.03411349281668663,
-0.2554607391357422,
0.9886693358421326,
-0.3201945424079895,
-0.20760156214237213,
0.23411400616168976,
0.0781506597995758,
-0.21389858424663544,
-0.29839184880256653,
-0.4487479031085968,
-0.6571146249771118,
0.3643324375152588,
-0.44329211115837097,
0.12304485589265... | |
x += curImage.getBounds().width;
}
//very important to dispose GC!!!
gc.dispose();
//now you can use bigImage
``` | [
0.1590709239244461,
-0.07526598870754242,
0.24677090346813202,
-0.17250609397888184,
0.004737426992505789,
-0.4443599581718445,
0.12807270884513855,
-0.12094293534755707,
-0.15011277794837952,
-0.5205431580543518,
-0.17149285972118378,
0.5878830552101135,
-0.5574622750282288,
0.24908743798... | |
I have a web directory where I store some config files. I'd like to use wget to pull those files down and maintain their current structure. For instance, the remote directory looks like:
```
http://mysite.com/configs/.vim/
```
.vim holds multiple files and directories. I want to replicate that on the client using wg... | [
0.2605706751346588,
-0.0480349101126194,
0.3461424708366394,
0.11192058026790619,
0.15195123851299286,
0.029954999685287476,
0.07579006254673004,
0.16036362946033478,
-0.22950129210948944,
-0.7626789212226868,
0.022726528346538544,
0.6607393622398376,
-0.1736360341310501,
0.498704701662063... | |
like this:
```
wget --recursive --no-parent http://example.com/configs/.vim/
```
To avoid downloading the auto-generated `index.html` files, use the `-R`/`--reject` option:
```
wget -r -np -R "index.html*" http://example.com/configs/.vim/
``` | [
-0.16795919835567474,
0.11996923387050629,
-0.0310265701264143,
-0.006556327920407057,
0.11623788625001907,
-0.17553414404392242,
0.3727704584598541,
0.08487994223833084,
-0.201882466673851,
-0.30330348014831543,
-0.5324813723564148,
0.4613947868347168,
-0.34140706062316895,
0.261971801519... | |
How can I figure out what is actually causing the following error? The page is the same as other pages but for some reason, only this page is having this error. It also only happens on the ISP (GoDaddy) who has a trust level of Medium and I can't set a breakpoint and try to catch it.
```
Server Error in '/' Applicatio... | [
-0.017128827050328255,
0.3145495057106018,
0.6173767447471619,
0.1919870674610138,
0.03857265040278435,
-0.3805014193058014,
0.7640075087547302,
0.03974687680602074,
-0.24371804296970367,
-0.7086664438247681,
-0.15602408349514008,
0.4984014928340912,
-0.29668354988098145,
0.244158878922462... | |
Request for the permission of type 'System.Security.Permissions.EnvironmentPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.
```
Source Error:
```
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and ... | [
-0.2707960903644562,
-0.02862532250583172,
0.6029372215270996,
-0.06641753017902374,
0.1459236890077591,
0.17189480364322662,
0.5143985748291016,
-0.42112985253334045,
-0.16719937324523926,
-0.3377054035663605,
-0.29005035758018494,
0.3129182457923889,
-0.340241014957428,
0.450020581483840... | |
A_2) +20
jg.b(c A_0, UInt64 A_1) +234
ei.b(c A_0, UInt64 A_1) +18
jg.a(c A_0, UInt64 A_1, Boolean A_2) +61
```
```
Version Information: Microsoft .NET Framework Version:2.0.50727.1433; ASP.NET Version:2.0.50727.1433
```
If you have had this issue or just know how I can fix or trace it please ad... | [
-0.10473842918872833,
0.19347427785396576,
0.3917880058288574,
0.0015064904000610113,
-0.12664057314395905,
-0.24881123006343842,
0.4921884834766388,
-0.23665966093540192,
-0.14683398604393005,
-0.5431289076805115,
-0.20558881759643555,
0.5641164183616638,
-0.3009612262248993,
0.0410694889... | |
a good habit to get into anyway. You want to test in an environment as close to production as possible. And the VS web server definitely has a few important differences that can get you if you don't test in IIS too.) | [
0.7069818377494812,
-0.15200456976890564,
0.001454749726690352,
0.4322080612182617,
0.015494206920266151,
-0.18269768357276917,
0.55687016248703,
-0.003863281337544322,
-0.08688420802354813,
-0.5140586495399475,
0.28420618176460266,
0.6799411773681641,
0.3270813822746277,
-0.01081625837832... | |
I have a bunch of controls on my window. One of them is a refresh button that performs a cumbersome task on a background thread.
When the user clicks the refresh button, I put the cursor in a wait (hourglass) status and disable the whole window -- `Me.IsEnabled = False`.
I'd like to support cancellation of the refres... | [
0.2906082272529602,
0.1491396427154541,
0.5230644941329956,
0.20364171266555786,
0.11172319948673248,
0.05748802423477173,
0.21257057785987854,
0.0471239909529686,
-0.1667870283126831,
-0.37207162380218506,
0.0762428343296051,
0.522179901599884,
-0.3751915395259857,
0.36114704608917236,
... | |
one when the user clicks cancel?
You can put all the controls in one panel (Grid, StackPanel, etc.), and leave the cancel button in another panel. Then set the IsEnabled property of the other panel.
In practice, this will probably introduce more than one additional panel.
For example, if you had a StackPanel of butto... | [
-0.19507448375225067,
-0.3707182705402374,
0.5016193985939026,
0.1368931233882904,
-0.004217263776808977,
-0.09453123062849045,
-0.32642364501953125,
-0.25040462613105774,
-0.4441327750682831,
-0.6210609078407288,
-0.17383304238319397,
0.6052654981613159,
-0.5574916005134583,
-0.1529233455... | |
false;
``` | [
0.044318050146102905,
0.4130396842956543,
-0.17376062273979187,
-0.2613368034362793,
0.008040736429393291,
-0.031185930594801903,
0.48932361602783203,
0.43068233132362366,
0.06855356693267822,
-0.199215367436409,
-0.5211203694343567,
0.7372800707817078,
-0.13847708702087402,
0.433188438415... | |
Currently it's a big PITA to create timesheet report for say a week or month in FogBugz... maybe someone knows about a plugin to that for you?
This question is kind of old so I am assuming you were using FB6, but if you are now using FB7 to do exactly this: [ClarkKent](http://www.fogcreek.com/FogBugz/Plugins/plugin.asp... | [
-0.0018400461412966251,
0.1918479949235916,
0.5294265747070312,
-0.12454879283905029,
-0.05907316878437996,
-0.016099898144602776,
0.39433959126472473,
0.24451041221618652,
-0.7562839984893799,
-0.20578880608081818,
0.058799900114536285,
0.28836774826049805,
-0.06017232686281204,
0.1888175... | |
Problem: I have an integer; this integer needs to be converted to a stl::string type.
In the past, I've used `stringstream` to do a conversion, and that's just kind of cumbersome. I know the C way is to do a `sprintf`, but I'd much rather do a C++ method that is typesafe(er).
Is there a better way to do this?
Here... | [
-0.3934273421764374,
-0.08894037455320358,
0.1923946589231491,
-0.24720454216003418,
-0.04904857277870178,
-0.00887814536690712,
0.2528626322746277,
-0.340230792760849,
-0.1318463236093521,
-0.7042116522789001,
-0.11277659237384796,
0.7416799068450928,
-0.38668346405029297,
-0.066301971673... | |
this could be rewritten as so:
```
template<class T>
std::string t_to_string(T i)
{
std::stringstream ss;
std::string s;
ss << i;
s = ss.str();
return s;
}
```
However, I have the notion that this is a fairly 'heavy-weight' implementation.
Zan noted that the invocation is pretty nice, however:
... | [
0.01461303886026144,
-0.007823286578059196,
0.41488054394721985,
-0.24939779937267303,
-0.15203724801540375,
-0.3352241516113281,
0.280865877866745,
-0.4256421625614166,
-0.10699132084846497,
-0.5030484199523926,
-0.2602428197860718,
0.691771388053894,
-0.428449422121048,
-0.10596210509538... | |
Is there a idiomatic way of removing elements from PATH-like shell variables?
That is I want to take
```
PATH=/home/joe/bin:/usr/local/bin:/usr/bin:/bin:/path/to/app/bin:.
```
and **remove** or **replace** the `/path/to/app/bin` without clobbering the rest of the variable. Extra points for allowing me *put* new ele... | [
0.10212843865156174,
0.16975829005241394,
-0.08521649986505508,
-0.11746972799301147,
-0.09558672457933426,
0.013627978973090649,
-0.02953520230948925,
-0.27152055501937866,
-0.22251714766025543,
-0.5919108390808105,
-0.05878356099128723,
0.6388736367225647,
-0.3066183924674988,
-0.1313903... | |
one of needing to switch conveniently between multiple versions (one for doing analysis, another for working on the framework) of a large scientific analysis package which produces a couple dozen executables, has data stashed around the filesystem, and uses environment variable to help find all this stuff. I would like... | [
0.31929489970207214,
0.07219555228948593,
-0.05998465046286583,
0.12216634303331375,
0.21377375721931458,
-0.309500515460968,
0.1695091873407364,
-0.07828491181135178,
-0.24320849776268005,
-0.6385112404823303,
-0.03484491631388664,
0.6968810558319092,
-0.4632321894168854,
0.07304289937019... | |
and the like.
---
* Previous similar question: [How to keep from duplicating path variable in csh](https://stackoverflow.com/questions/135754/how-to-keep-from-duplicating-path-variable-in-csh)
* Subsequent similar question: [What is the most elegant way to remove a path from the $PATH variable in Bash?](https://stack... | [
-0.18443048000335693,
-0.01779005117714405,
0.30276963114738464,
-0.2515372335910797,
-0.25426334142684937,
-0.08292817324399948,
0.20314735174179077,
-0.309248149394989,
-0.17548847198486328,
-0.3900608420372009,
-0.24036583304405212,
0.7223718166351318,
-0.456566721200943,
-0.11883661150... | |
global variable - something to be avoided whenever possible.
5. I'm not sure what you expect '`replace-path PATH $PATH /usr`' to do, but it does not do what I would expect.
Consider a PATH value that starts off containing:
```
.
/Users/jleffler/bin
/usr/local/postgresql/bin
/usr/local/mysql/bin
/Users/jleffler/perl/v... | [
-0.47082677483558655,
-0.17194998264312744,
0.6473300457000732,
0.11693628132343292,
0.10729663074016571,
0.08647216111421585,
-0.08261629194021225,
0.11841722577810287,
-0.531809389591217,
-0.3637048900127411,
0.009035921655595303,
0.6355255246162415,
-0.571675717830658,
0.044684875756502... | |
tr "\n" ":" | sed "s|::|:|g")
```
I used ':' instead of '|' to separate parts of the substitute since '|' could (in theory) appear in a path component, whereas by definition of PATH, a colon cannot. I observe that the second `sed` could eliminate the current directory from the middle of a PATH. That is, a legitimate ... | [
-0.22212570905685425,
-0.09633044898509979,
0.47900262475013733,
-0.1468011438846588,
0.040174875408411026,
0.101484015583992,
0.02983277291059494,
-0.3609585762023926,
0.14496098458766937,
-0.6606292128562927,
-0.32599905133247375,
0.5591611266136169,
-0.4882529079914093,
0.15864390134811... | |
| grep -m 1 "^$pat\$")
```
I note in passing that `grep -m 1` is not standard (it is a GNU extension, also available on MacOS X). And, indeed, the`-n` option for `echo` is also non-standard; you would be better off simply deleting the trailing colon that is added by virtue of converting the newline from echo into a c... | [
-0.23356375098228455,
0.047089070081710815,
0.4331756830215454,
-0.30142951011657715,
-0.08079451322555542,
-0.14021560549736023,
0.34989994764328003,
-0.05921241641044617,
-0.28291642665863037,
-0.4631996154785156,
-0.5027552843093872,
0.30482789874076843,
-0.7180529236793518,
-0.07335286... | |
expansion, leads to:
```
# path_tools.bash
#
# A set of tools for manipulating ":" separated lists like the
# canonical $PATH variable.
#
# /bin/sh compatibility can probably be regained by replacing $( )
# style command expansion with ` ` style
#########################################################################... | [
0.1830843985080719,
-0.27634233236312866,
0.7345681190490723,
0.04302095249295235,
0.23379972577095032,
-0.17225708067417145,
0.02847730554640293,
-0.6257051825523376,
-0.6094240546226501,
-0.8545175790786743,
-0.33041247725486755,
0.5615042448043823,
-0.4227227568626404,
0.122160039842128... | |
of $1
#
# $1 name of the shell variable to set (e.g. PATH)
# $2 a ":" delimited list to work from (e.g. $PATH)
# $3 the precise string to be removed/replaced
# $4 the replacement string (use "" for removal)
function replace_path () {
path=$1
list=$2
remove=$3
replace=$4 # Allowed to be em... | [
0.11612056940793991,
-0.2673824429512024,
0.4196373522281647,
-0.38406670093536377,
0.30938541889190674,
-0.02944999374449253,
0.19546747207641602,
-0.568956196308136,
0.029310600832104683,
-0.29928794503211975,
-0.35640522837638855,
0.8951659798622131,
-0.7659810185432434,
-0.091958120465... | |
tr "\n" ":" | sed 's|:$||')
}
# Remove or replace an element of $1
#
# $1 name of the shell variable to set (e.g. PATH)
# $2 a ":" delimited list to work from (e.g. $PATH)
# $3 a grep pattern identifying the element to be removed/replaced
# $4 the replacement string (use "" for removal)
function replace_path_p... | [
-0.11262863874435425,
-0.26567748188972473,
0.4256093204021454,
-0.19355183839797974,
0.28936100006103516,
0.1341918408870697,
0.08161139488220215,
-0.4061185419559479,
-0.19051575660705566,
-0.28125035762786865,
-0.44044312834739685,
0.7863529324531555,
-0.6329990029335022,
0.012281104922... | |
or unset
removestr=$(echo "$list" | tr ":" "\n" | grep -m 1 "^$removepat\$")
replace_path "$path" "$list" "$removestr" "$replacestr"
}
```
I have a Perl script called `echopath` which I find useful when debugging problems with PATH-like variables:
```
#!/usr/bin/perl -w
#
# "@(#)$Id: echopath.pl,v 1.7 199... | [
0.08721083402633667,
0.008001753129065037,
0.29830414056777954,
-0.299154669046402,
0.009556380100548267,
0.14946796000003815,
0.5223812460899353,
-0.46631118655204773,
-0.19870778918266296,
-0.22422708570957184,
-0.18635545670986176,
0.6278687119483948,
-0.9690043330192566,
0.089034840464... | |
= $ENV{$arg} if $arg =~ /^[A-Za-z_][A-Za-z_0-9]*$/;
$var = $arg unless $var;
@lst = split /:/, $var;
foreach $val (@lst)
{
print "$val\n";
}
}
```
When I run the modified solution on the test code below:
```
echo
xpath=$PATH
replace_path xpath $xpath /usr
echopath $xpath
echo
xpath=$... | [
0.2845892906188965,
0.15246252715587616,
0.4264388382434845,
-0.241594597697258,
0.007998193614184856,
0.142462819814682,
0.6006261706352234,
-0.8308854699134827,
-0.029380833730101585,
-0.33505597710609436,
-0.058990705758333206,
0.4826087951660156,
-0.5645867586135864,
-0.188129752874374... | |
if your functions were able to do that, so the user could type:
```
replace_path PATH /usr/bin /work/bin
```
That can be done by using:
```
list=$(eval echo '$'$path)
```
This leads to this revision of the code:
```
# path_tools.bash
#
# A set of tools for manipulating ":" separated lists like the
# canonical $P... | [
0.147713765501976,
-0.3329307436943054,
0.5524620413780212,
0.16459603607654572,
0.08292761445045471,
-0.21139562129974365,
0.31145328283309937,
-0.40293219685554504,
-0.34201058745384216,
-0.6274052858352661,
-0.2684113383293152,
0.760582447052002,
-0.35001033544540405,
-0.187469154596328... | |
PATH /exact/path/to/remove /replacement/path
# replace_path_pattern PATH <target pattern> /replacement/path
#
###############################################################################
# Remove or replace an element of $1
#
# $1 name of the shell variable to set (e.g. PATH)
# $2 the precise string to be re... | [
0.1743653565645218,
-0.1871509701013565,
0.27025219798088074,
-0.3590264320373535,
0.22995847463607788,
0.10067860782146454,
0.29976382851600647,
-0.6911078691482544,
-0.1924571394920349,
-0.36309880018234253,
-0.07907208055257797,
0.7417707443237305,
-0.7760552763938904,
-0.24193373322486... | |
"$list" | tr ":" "\n" | sed "s:^$remove\$:$replace:" |
tr "\n" ":" | sed 's|:$||')
}
# Remove or replace an element of $1
#
# $1 name of the shell variable to set (e.g. PATH)
# $2 a grep pattern identifying the element to be removed/replaced
# $3 the replacement string (use "" for removal)
fun... | [
-0.06043035164475441,
-0.28916701674461365,
0.3254355788230896,
-0.3105166256427765,
0.219196155667305,
0.054288119077682495,
0.15400728583335876,
-0.5439607501029968,
-0.22417066991329193,
-0.2515362799167633,
-0.43647700548171997,
0.6901368498802185,
-0.7688379287719727,
-0.0178520251065... | |
# Allowed to be empty or unset
removestr=$(echo "$list" | tr ":" "\n" | grep -m 1 "^$removepat\$")
replace_path "$path" "$removestr" "$replacestr"
}
```
The following revised test now works too:
```
echo
xpath=$PATH
replace_path xpath /usr
echopath xpath
echo
xpath=$PATH
replace_path_pattern xpath /usr/bin... | [
0.24587561190128326,
-0.24170663952827454,
0.456918329000473,
-0.4753829538822174,
-0.0601675920188427,
-0.07255946844816208,
0.45783960819244385,
-0.7411377429962158,
0.10861063748598099,
-0.3354938328266144,
0.007252461276948452,
0.7238048911094666,
-0.6572495102882385,
-0.16235515475273... | |
I am trying to write a function that will pull the name of a property and the type using syntax like below:
```
private class SomeClass
{
Public string Col1;
}
PropertyMapper<Somewhere> propertyMapper = new PropertyMapper<Somewhere>();
propertyMapper.MapProperty(x => x.Col1)
```
Is there any way to pass the pro... | [
0.054194021970033646,
0.01956522837281227,
0.38275793194770813,
-0.11163611710071564,
0.05784226953983307,
-0.07338954508304596,
-0.034695103764534,
-0.14518901705741882,
-0.15780185163021088,
-0.5066291093826294,
-0.32368454337120056,
0.35438424348831177,
-0.28625258803367615,
0.268607616... | |
get you started:
```
public static MemberInfo GetMemberInfo<T, U>(Expression<Func<T, U>> expression)
{
var member = expression.Body as MemberExpression;
if (member != null)
return member.Member;
throw new ArgumentException("Expression is not a member access", "expression");
}
```
Calling code wo... | [
0.20960204303264618,
-0.2682822346687317,
0.361784428358078,
-0.11777841299772263,
0.07347086817026138,
-0.2657507359981537,
0.35126951336860657,
-0.3864361643791199,
-0.500855565071106,
-0.4181579649448395,
-0.4786263704299927,
0.5078213214874268,
-0.3338080942630768,
0.25285160541534424,... | |
ReflectionUtility.GetMemberInfo((Program p) => p.Name);
Console.WriteLine(member.Name);
}
}
```
A word of caution, though: the simple statment of `(Program p) => p.Name` actually involves quite a bit of work (and can take measurable amounts of time). Consider caching the result rather than calling the met... | [
0.12176790833473206,
-0.20154394209384918,
0.2522122263908386,
0.0065247374586761,
0.02987794205546379,
-0.4115293323993683,
0.1791399121284485,
-0.41445115208625793,
0.10929744690656662,
-0.18825869262218475,
-0.01863039843738079,
0.7160483598709106,
-0.10886784642934799,
0.05618820711970... | |
How does one prevent an inclusion cycle in C? ie. You shouldn't have a.h #include "b.h", which #include's "c.h" which #include's "a.h". I'm looking for a way of preventing this from happening using some sort of C directive.
I had originally thought this would've prevented this from happening:
Contents of a.h:
```
#i... | [
0.2452332228422165,
0.37134501338005066,
-0.15131787955760956,
-0.1278390735387802,
0.09083618968725204,
-0.26783642172813416,
0.1648513674736023,
-0.3085886836051941,
-0.31230902671813965,
-0.4867427945137024,
-0.19951167702674866,
0.43911024928092957,
-0.6141558289527893,
0.1128457114100... | |
preprocessed output and look at it for yourself. With GNU CC, you need to use "-E" option on the .c[pp] file, like this:
```
gcc -E $(CFLAGS) -o foo.i foo.cpp
``` | [
0.4343431293964386,
0.21471400558948517,
0.49445396661758423,
0.0720970407128334,
-0.06964283436536789,
-0.2284911572933197,
-0.45979073643684387,
0.00831467006355524,
-0.3838379681110382,
-0.31161412596702576,
-0.34306976199150085,
0.7003653049468994,
-0.4611726403236389,
0.03813614696264... | |
I would like to know if there is software that, given a regex and of course some other constraints like length, produces random text that always matches the given regex.
Thanks
[Xeger](http://code.google.com/p/xeger) is capable of doing it:
```
String regex = "[ab]{4,6}c";
Xeger generator = new Xeger(regex);
String r... | [
0.26483288407325745,
0.19213736057281494,
0.37442266941070557,
0.09632846713066101,
-0.07368660718202591,
-0.02907833643257618,
0.06625334173440933,
-0.2640000283718109,
-0.06463267654180527,
-0.39966338872909546,
-0.08654213696718216,
0.44692263007164,
-0.31492918729782104,
0.156263411045... | |
I'm increasingly becoming aware that there must be major differences in the ways that regular expressions will be interpreted by browsers.
As an example, a co-worker had written this regular expression, to validate that a file being uploaded would have a PDF extension:
```
^(([a-zA-Z]:)|(\\{2}\w+)\$?)(\\(\w[\w].*))... | [
0.12133054435253143,
0.040087949484586716,
0.6539046764373779,
-0.20127356052398682,
-0.12008770555257797,
-0.2855224311351776,
0.30273571610450745,
-0.045656103640794754,
-0.04413066431879997,
-0.8103895783424377,
-0.07691974192857742,
0.8219413161277771,
-0.43775200843811035,
-0.24657614... | |
quirk specific to asp:FileUpload and RegularExpressionValidator controls in ASP.NET, or is it simply due to different browsers supporting regex in different ways? Either way, what are some of the latter that you've encountered?
As far as I know firefox doesn't let you have the full path of an upload. Interpretation of ... | [
0.3263989984989166,
-0.27084818482398987,
0.18991480767726898,
0.21815000474452972,
-0.3900761604309082,
-0.09536515921354294,
0.3209024965763092,
0.4115365445613861,
-0.5193506479263306,
-0.32913658022880554,
0.07506012916564941,
0.7206898331642151,
-0.3864075243473053,
-0.079476639628410... | |
Is keeping JMS connections / sessions / consumer always open a bad practice?
Code draft example:
```
// app startup code
ConnectionFactory cf = (ConnectionFactory)jndiContext.lookup(CF_JNDI_NAME);
Connection connection = cf.createConnection(user,pass);
Session session = connection.createSession(true,Session.TRANSACT... | [
0.131617471575737,
-0.1255018413066864,
0.7004204988479614,
-0.3733152151107788,
0.005484277382493019,
-0.035819947719573975,
0.45136457681655884,
-0.0685032531619072,
-0.5333397388458252,
-0.6419655680656433,
-0.5438312888145447,
0.5926842093467712,
-0.38428962230682373,
0.377556562423706... | |
I have a very painful library which, at the moment, is accepting a C# string as a way to get arrays of data; apparently, this makes marshalling for pinvokes easier.
So how do I make a ushort array into a string by bytes? I've tried:
```
int i;
String theOutData = "";
ushort[] theImageData = inImageData.DataArray;
/... | [
0.23067447543144226,
-0.0025785821489989758,
0.29395273327827454,
-0.1104835644364357,
-0.06200013682246208,
0.16301250457763672,
0.6648917198181152,
-0.4115132689476013,
-0.22530987858772278,
-0.7187414169311523,
-0.09300526976585388,
0.5321620106697083,
-0.07137951999902725,
0.2707517445... | |
to a sane amount of time.
What should I do here? Go unsafe? Go through some kind of IntPtr intermediate?
If it were a char\* in C++, this would be significantly easier...
edit: the function call is
```
DataElement.SetByteValue(string inArray, VL Length);
```
where VL is a 'Value Length', a DICOM type, and the fun... | [
0.12096048891544342,
-0.2918991148471832,
0.28960102796554565,
-0.005560444202274084,
0.09377333521842957,
-0.024089917540550232,
0.13949279487133026,
-0.2114664763212204,
-0.07561153173446655,
-0.36250442266464233,
-0.18401099741458893,
0.4463478624820709,
-0.3850693702697754,
0.295277625... | |
to set your image buffer pointer, in C++ it's fairly simple, but in C#, I'm stuck with this weird problem.
This is hackeration, and I know that probably the best thing is to make the SWIG library work right. I really don't know how to do that, and would rather a quick workaround on the C# side, if such exists.
P/Invok... | [
0.3896053731441498,
-0.02999822236597538,
0.42293283343315125,
-0.09034862369298935,
-0.10450929403305054,
-0.00759577751159668,
0.12339048087596893,
0.0044104172848165035,
-0.25771841406822205,
-0.5818726420402527,
0.06373502314090729,
0.5862883925437927,
-0.4448789358139038,
-0.180251523... | |
is the case you can use Encoding.Unicode.GetString(), but that will exepect a byte array rather than a ushort array. To turn your ushorts into bytes, you can allocate a separate byte array and use Buffer.BlockCopy, something like this:
```
ushort[] data = new ushort[10];
for (int i = 0; i < data.Length; ++i)
data[... | [
0.08231251686811447,
-0.02741062641143799,
0.4286291003227234,
-0.21852974593639374,
0.020287249237298965,
0.2686188519001007,
0.24807873368263245,
-0.3976123332977295,
-0.2753756642341614,
-0.6216581463813782,
-0.43842145800590515,
0.4523194134235382,
-0.4214682877063751,
-0.1156702935695... | |
the string constructor, like so:
```
string asString;
unsafe
{
fixed (ushort *dataPtr = &data[0])
asString = new string((char *) dataPtr, 0, data.Length);
}
``` | [
-0.15804129838943481,
-0.059605590999126434,
0.2707805037498474,
-0.18813501298427582,
0.023364923894405365,
0.1047312319278717,
0.2350924015045166,
-0.1926434487104416,
-0.12602701783180237,
-0.18005774915218353,
-0.2053932547569275,
0.6363740563392639,
-0.4503002166748047,
0.214633926749... | |
Is there a specific reason why I should be using the `Html.CheckBox`, `Html.TextBox`, etc methods instead of just manually writing the HTML?
```
<%= Html.TextBox("uri") %>
```
renders the following HTML
```
<input type="text" value="" name="uri" id="uri"/>
```
It guess it saves you a few key strokes but other tha... | [
-0.0016704136505723,
0.16859784722328186,
0.5271790623664856,
0.030076157301664352,
-0.4312015175819397,
-0.12270976603031158,
0.2583801746368408,
-0.09726966172456741,
-0.01619463600218296,
-0.7084051966667175,
0.07862430065870285,
0.5140681862831116,
-0.23006942868232727,
-0.123258516192... | |
to override the rendering by providing your own DLL for changing the rendering (a sort of "Controller Adapter" type methodology).
It leads to the idea of building your own "controls" : <http://www.singingeels.com/Articles/Building_Custom_ASPNET_MVC_Controls.aspx> | [
0.11465591937303543,
-0.292639821767807,
0.29163751006126404,
0.41116657853126526,
-0.0006368667236529291,
0.015440687537193298,
0.5181302428245544,
-0.5014905333518982,
-0.28797951340675354,
-0.16871166229248047,
-0.012202144600450993,
0.48715314269065857,
-0.19086900353431702,
-0.1649174... | |
I've got a large number of integer arrays. Each one has a few thousand integers in it, and each integer is generally the same as the one before it or is different by only a single bit or two. I'd like to shrink each array down as small as possible to reduce my disk IO.
Zlib shrinks it to about 25% of its original siz... | [
0.30476489663124084,
0.20613469183444977,
0.2940225601196289,
0.01038188487291336,
0.0042348578572273254,
-0.11178716272115707,
0.00514086103066802,
0.13544654846191406,
-0.4121930003166199,
-0.6609669327735901,
-0.06516646593809128,
0.4422367513179779,
-0.1666032373905182,
0.1369154006242... | |
converting it to an array of xor deltas shrinks it to about 20% of the original size.
If most of the integers really are the same as the previous, and the inter-symbol difference can usually be expressed as a single bit flip, this sounds like a job for XOR.
Take an input stream like:
```
1101
1101
1110
1110
0110
```... | [
0.03485610708594322,
0.07724885642528534,
0.384527325630188,
-0.172590970993042,
-0.05865300074219704,
0.4497043192386627,
0.1410737782716751,
-0.6400855183601379,
-0.16498371958732605,
-0.5420635342597961,
-0.04624131694436073,
0.41553816199302673,
-0.39097827672958374,
-0.135082080960273... | |
on 32-bit integers, and it can still encode a radically different integer popping up in the stream. You're saved the bother of dealing with bit-packing yourself, as everything remains an int-sized quantity.
When you want to decompress:
```
uncompressed[0] = compressed[0]
loop
uncompressed[i] = uncompressed[i-1] ^ c... | [
-0.08114347606897354,
-0.017693111672997475,
0.26065608859062195,
-0.01686188392341137,
-0.06858192384243011,
0.008578126318752766,
0.12330307811498642,
-0.22152560949325562,
-0.39980459213256836,
-0.36912277340888977,
-0.30956724286079407,
0.4425654411315918,
-0.4345828890800476,
0.022064... | |
I would like to be able to dictate into my Delphi application using Microsoft Vista's speech recognition. However when attempting to dictate into a TMemo, it simply does not work. I noticed that Firefox 3.0 has the same issue and after they contacted Microsoft about the problem, they [told them](https://bugzilla.mozill... | [
0.2959783971309662,
0.23911277949810028,
0.3918408751487732,
-0.12947770953178406,
0.105225570499897,
-0.09898186475038528,
0.36548852920532227,
0.061507172882556915,
0.11015722900629044,
-0.7628819346427917,
-0.17992554605007172,
0.621941089630127,
-0.4181235432624817,
0.12835755944252014... | |
finding a solution?
**Edit:** I found out that there is a way to enable speech recognition in all programs, even those that don't support it, simply by going to the options of Windows Speech Recognition and selecting **Enable dictation everywhere**. However when you use this to dictate into an editbox that doesn't use... | [
-0.1544768214225769,
-0.03153800964355469,
0.28725749254226685,
0.2819910943508148,
0.2670157551765442,
0.29325953125953674,
0.4450839161872864,
-0.006428247783333063,
-0.13533686101436615,
-0.7554624676704407,
-0.2062525600194931,
0.40143850445747375,
-0.3935708999633789,
-0.1073973625898... | |
a word. So I am still trying to figure out how to enable speech recognition without relying on the **Enable dictation everywhere** option.
I found out that there is a way to enable speech recognition in all programs, even those that don't support it, simply by going to the options of Windows Speech Recognition and sele... | [
0.11847487092018127,
-0.04081488400697708,
0.4641169011592865,
0.001996387029066682,
-0.2165142446756363,
0.38844555616378784,
0.6279261112213135,
0.016310710459947586,
-0.1834619641304016,
-0.6238877177238464,
-0.25263917446136475,
0.3753010630607605,
-0.23741503059864044,
-0.059183787554... | |
may work for short sentences, it does not have many of the useful features such as correcting or deleting a word. | [
-0.27074262499809265,
-0.005903648212552071,
-0.028668325394392014,
0.1723252683877945,
-0.0030849322210997343,
-0.20460866391658783,
0.8133903741836548,
0.3338967263698578,
0.16427136957645416,
-0.1547616720199585,
-0.5965765714645386,
0.2248932421207428,
0.15985949337482452,
-0.291338145... | |
I can't for the life of me find a way to make this work.
If I have 3 divs (a left sidebar, a main body, and a footer), how can I have the sidebar and main body sit next to each other without setting their positions as "absolute" or floating them? Doing either of these options result in the footer div not being pushed ... | [
0.1518457978963852,
-0.14288349449634552,
0.6262310147285461,
0.19771863520145416,
-0.10152348130941391,
0.10882997512817383,
-0.2520575225353241,
-0.12509086728096008,
-0.4037996530532837,
-0.6034075021743774,
0.5730782747268677,
0.28556588292121887,
0.08943846821784973,
-0.09523089975118... | |
for:

Here's a simplified version of the HTML I currently have set up:
```
<div id="sidebar"></div>
<div id="content"></div>
<div id="footer"></div>
```
You need to specify the footer to clear the float:
```
#footer{
clear: both;
}
```
This forces it under floated... | [
0.04616013541817665,
-0.03141516447067261,
0.7361071109771729,
-0.13661718368530273,
-0.01927129738032818,
0.03628312423825264,
-0.22333399951457977,
-0.31709542870521545,
-0.24600352346897125,
-0.4729153513908386,
-0.07455500960350037,
0.17356708645820618,
-0.04535898193717003,
0.04193047... | |
Does anyone know of an already implemented money type for the .NET framework that supports i18n (currencies, formatting, etc)? I have been looking for a well implemented type and can't seem to find one.
Check this article [A Money type for the CLR](http://www.codeproject.com/KB/recipes/MoneyTypeForCLR.aspx)
> A conven... | [
0.09165631979703903,
0.21906493604183197,
0.30839625000953674,
0.2040776163339615,
0.09197189658880234,
-0.06475275009870529,
-0.3764113783836365,
0.04065726697444916,
-0.49873828887939453,
-0.3833255469799042,
0.07177633047103882,
0.4712822735309601,
-0.036875784397125244,
-0.193706259131... | |
I want to setup a statistics monitoring platform to watch a specific service, but I'm not quiet sure how to go about it. Processing the intercepted data isn't my concern, just how to go about it. One idea was to setup a proxy between the client application and the service so that all TCP traffic went first to my proxy,... | [
0.33120840787887573,
-0.052591755986213684,
0.2540714740753174,
0.16221611201763153,
0.034064680337905884,
-0.07072828710079193,
0.10516002029180527,
0.23956234753131866,
-0.1736094057559967,
-0.621406078338623,
0.3143182396888733,
0.2568845748901367,
-0.34478455781936646,
0.11730952560901... | |
serious loss in transmission speed between client & application but get 100% complete communications between client & service.
Environment: UBuntu 8.04
Language: c/c++
In the background I was thinking of using a sqlite DB running completely in memory or a 20-25MB memcache dameon slaved to my process.
Update:
Speci... | [
-0.10206282883882523,
0.23513337969779968,
0.40840795636177063,
-0.01872830092906952,
-0.17855165898799896,
-0.24105651676654816,
0.4505355954170227,
0.023362627252936363,
-0.004863483365625143,
-0.8905959725379944,
-0.2432669699192047,
0.5559958815574646,
-0.4494136571884155,
0.1474426239... | |
keys apart by a configured separator and record statistics on them.
You didn't mention one approach: you could modify memcached or your client to record the statistics you need. This is probably the easiest and cleanest approach.
Between the proxy and the libpcap approach, there are a couple of tradeoffs:
```
- If yo... | [
0.11093737185001373,
-0.25284168124198914,
0.0966041162610054,
0.42899590730667114,
0.028680462390184402,
-0.3499927520751953,
0.19280603528022766,
-0.11641212552785873,
-0.5239530801773071,
-0.6230644583702087,
-0.06922616809606552,
0.640052318572998,
-0.3225194215774536,
0.16933912038803... | |
capture is transparent.
- If you do the proxy approach, the kernel handles all the TCP work for
you. You'll never lose requests. But if your monitor bogs down, it'll bog
down the app. And if your monitor crashes, it'll break caching. You
probably will have to reconfigure your app and/or memcached servers so
t... | [
0.15994924306869507,
0.01193159632384777,
0.3241950571537018,
0.20941473543643951,
0.027941681444644928,
-0.14586426317691803,
-0.04732542857527733,
0.00028112984728068113,
-0.40191659331321716,
-0.6220173835754395,
-0.19599971175193787,
0.6786379218101501,
-0.6604633331298828,
-0.05484954... | |
like the sanest approach to me.
BTW: You have looked at memcached's built-in statistics reporting? I don't think its granular enough for what you want, but if you haven't seen it, take a look before doing actual work :-D | [
0.44201287627220154,
-0.06533613055944443,
0.021674921736121178,
0.19882652163505554,
-0.04585922509431839,
-0.07901069521903992,
0.022489387542009354,
0.21426540613174438,
-0.12401765584945679,
-0.32365286350250244,
0.25632956624031067,
0.18968957662582397,
0.08842360228300095,
-0.1967003... | |
Is anyone aware of any gems, tutorials, or solutions enabling a user to sign in to a website at one domain and automatically given access to other partner domains in the same session?
I have two rails apps running, let's call them App-A and App-B. App-A has a database associated with it, powering the registration and... | [
0.6435659527778625,
0.3738291263580322,
0.13492260873317719,
0.12220364063978195,
0.06463325768709183,
-0.035563550889492035,
0.5611278414726257,
-0.13872483372688293,
-0.2962716519832611,
-0.4727358818054199,
0.2393246591091156,
0.623111367225647,
0.13411077857017517,
-0.05375421792268753... | |
change the session\_key, like this
```
Rails::Initializer.run do |config|
...
config.action_controller.session = {
:session_key => '_portal_session',
:secret => '72bf006c18d459acf51836d2aea01e0afd0388f860fe4b07a9a57dedd25c631749ba9b65083a85af38bd539cc810e81f559e76d6426c5e77b6064f42e14f7415'
}
...
... | [
-0.16466881334781647,
-0.2435113787651062,
0.4352867901325226,
-0.03758981451392174,
0.1703704297542572,
-0.09117286652326584,
0.2646807134151459,
-0.12727060914039612,
-0.27267175912857056,
-0.8948893547058105,
-0.22794176638126373,
0.5554434657096863,
-0.44026979804039,
0.085158310830593... | |
We're using Stored Procedures for *every query* to the DB. This seems incredibly un-[DRY](http://en.wikipedia.org/wiki/Don%27t_repeat_yourself):
1. Design the table
2. Design CRUD operation SPs for that table
3. Design code (preferably a class) to fill parameters and execute CRUD SPs
If we add a single column, or cha... | [
0.24530522525310516,
0.16190195083618164,
0.5219774842262268,
0.15084144473075867,
0.054266154766082764,
-0.10191231220960617,
0.09685232490301132,
-0.42573997378349304,
-0.37247639894485474,
-0.5789199471473694,
0.02696073055267334,
0.30891305208206177,
-0.40072494745254517,
0.08446183800... | |
comm = new SqlCommand("NameOfStoredProcedure", conn);
comm.CommandType = CommandType.StoredProcedure;
conn.Open();
SqlCommandBuilder.DeriveParameters(comm);
conn.Close();
foreach (SqlParameter param in comm.Parameters)
{ /* do stuff */ }
```
One tip to avoid modification of at least the SPs is writing them to use 'i... | [
0.03665665164589882,
0.049642790108919144,
0.8689701557159424,
0.15002216398715973,
0.03211648389697075,
-0.008307868614792824,
0.1856948584318161,
-0.3348427414894104,
-0.3293675184249878,
-0.4593795835971832,
-0.22126704454421997,
0.4774426221847534,
-0.40151697397232056,
0.0284556206315... | |
the rest of SPs.
By the way, this can get very complex and even unfeasible if your queries are complex, but on the other hand, if they are not, it can save you a lot of trouble. | [
0.29233261942863464,
0.0407613180577755,
0.22404058277606964,
0.38918688893318176,
0.021001480519771576,
-0.41383904218673706,
0.33901292085647583,
0.03842852637171745,
-0.17112000286579132,
-0.4109365940093994,
-0.02166368067264557,
0.5823593735694885,
-0.07764214277267456,
-0.10733512043... | |
This works (prints, for example, “3 arguments”):
```
to run argv
do shell script "echo " & (count argv) & " arguments"
end run
```
This doesn't (prints only “Argument 3: three”, and not the previous two arguments):
```
to run argv
do shell script "echo " & (count argv) & " arguments"
repeat with i from... | [
-0.021070674061775208,
0.36969897150993347,
0.2958890199661255,
-0.551813006401062,
0.0547141432762146,
-0.03168308362364769,
0.6569475531578064,
-0.983214259147644,
-0.13457757234573364,
-0.0061324662528932095,
-0.1796400398015976,
0.7770419120788574,
-0.46036282181739807,
-0.301358252763... | |
using `osascript` on Mac OS X 10.5.5. Example invocation:
```
osascript 'Script that takes arguments.applescript' Test argument three
```
I'm not redirecting the output, so I know that the script is not throwing an error.
If I add a `display dialog` statement above the `do shell script`, it throws a “no user intera... | [
-0.0577101968228817,
0.196901336312294,
0.2814747989177704,
-0.283603310585022,
-0.2289275974035263,
-0.19276149570941925,
0.5392109155654907,
-0.1681659072637558,
-0.19672785699367523,
-0.6713892221450806,
-0.040342021733522415,
0.6139868497848511,
-0.7752154469490051,
-0.1064746752381324... | |
script "echo " & (count argv) & " arguments" altering line endings false
repeat with i from 1 to (count argv)
set ln to do shell script "echo 'Argument " & i & ": " & (item i of argv) & "'" altering line endings false
set accumulator to accumulator & ln
end repeat | [
-0.16983824968338013,
0.14719948172569275,
0.5284836888313293,
-0.48814111948013306,
0.010825802572071552,
0.44132086634635925,
0.3718942105770111,
-0.7059429883956909,
0.22728289663791656,
-0.32650983333587646,
-0.3074794411659241,
0.45086920261383057,
-0.24025174975395203,
-0.18802773952... | |
return accumulator
end run
``` | [
-0.28337541222572327,
-0.003939524758607149,
0.311617374420166,
-0.1315748393535614,
0.07143658399581909,
-0.2741034924983978,
0.2494429647922516,
0.16581270098686218,
0.33677175641059875,
-0.19539938867092133,
-0.4334608018398285,
0.5307196378707886,
-0.3530329167842865,
0.226608648896217... | |
I've built web apps before that utilize phpBB session, and user data. The common move is to use code like this:
```
define('IN_PHPBB', true);
//replace $phpbb_root_path with path to your forum
$phpbb_root_path = '../forum/';
$phpEx = substr(strrchr(__FILE__, '.'), 1);
include($phpbb_root_path . 'common.' . $phpEx);
/... | [
0.18783307075500488,
0.37582075595855713,
0.6297711133956909,
-0.1415274441242218,
0.08324267715215683,
-0.4625607430934906,
0.4503219723701477,
-0.2503999173641205,
-0.2884499132633209,
-0.7994557619094849,
-0.07040373980998993,
0.8554496169090271,
-0.38562148809432983,
-0.011116788722574... | |
user is logged in `$user->data[username] == Anonymous`
2. Utilize data from '$user->data' such as the user's ID, screenname, etc.
Could I grab the `$user->data` array, and somehow save it to my own session? Does anyone have any ideas on this? Thanks in advance!
Two things:
* I would make the default block size a *lot... | [
0.08982762694358826,
0.1555582880973816,
0.6390585899353027,
-0.08211298286914825,
0.07456668466329575,
-0.025705261155962944,
0.2725893557071686,
-0.19678910076618195,
-0.3780209422111511,
-0.8125558495521545,
0.07249686866998672,
0.7476846575737,
-0.20452998578548431,
-0.1464779675006866... | |
= None):
while True:
# copy loop stuff
if callback:
callback(pos, total)
prog = ProgressBar(...)
copy_with_prog(src, dest, lambda pos, total: prog.update(pos, total))
``` | [
0.31696617603302,
0.038153938949108124,
0.46212759613990784,
-0.16405561566352844,
0.4052794575691223,
-0.168615460395813,
0.3191211521625519,
-0.3061509132385254,
-0.29851585626602173,
-0.21191824972629547,
-0.4055919051170349,
0.6433866620063782,
-0.5034933686256409,
0.1035052016377449,
... | |
Am working with django Publisher example, I want to list all the publishers in the db via my list\_publisher.html template, my template looks like;
```
{% extends "admin/base_site.html" %}
{% block title %}List of books by publisher{% endblock %}
{% block content %}
<div id="content-main">
<h1>List of publisher:</h1>... | [
0.19312074780464172,
0.7504942417144775,
0.5112860202789307,
-0.32054853439331055,
-0.1900051385164261,
-0.37171244621276855,
0.26833632588386536,
-0.6030386090278625,
0.08138929307460785,
-0.5091422200202942,
-0.025345906615257263,
0.5437511801719666,
-0.24112781882286072,
0.0395326204597... | |
list\_publisher.html
* check the cardinality of your list: `{%regroup publisher by name as pub_list %}{{ pub_list|length }}`. That should at least display the length of your list. If is is '0'... you know why it does not display anything
* check that your list is indeed sorted by name before using regroup, or use a `{%... | [
-0.22293789684772491,
0.09941049665212631,
0.7728103995323181,
0.04115964472293854,
-0.2360869199037552,
-0.22311002016067505,
0.03562027961015701,
-0.3017609715461731,
-0.6259304881095886,
-0.7480801343917847,
-0.2802504003047943,
0.3083808124065399,
-0.5093361139297485,
0.104799561202526... | |
Publisher.objects.all().order_by("name")
```
?
(again, the order by name is important, to ensure your regroup tag works properly) | [
0.11624401807785034,
0.28925076127052307,
0.1585151106119156,
0.018004583194851875,
-0.19676175713539124,
-0.22487907111644745,
0.028284510597586632,
0.03778858482837677,
-0.4862726628780365,
-0.47765052318573,
-0.4401703178882599,
0.23744244873523712,
-0.6263296008110046,
0.31943982839584... | |
Is there an easy way to verify that a given private key matches a given public key? I have a few `*.pub`and a few `*.key` files, and I need to check which go with which.
Again, these are pub/key files, DSA.
I would really prefer a one-liner of some sort...
I found a way that seems to work better for me:
```
ssh-keyg... | [
0.34514641761779785,
0.13512231409549713,
0.316033273935318,
-0.057835835963487625,
-0.1531854271888733,
0.1488955169916153,
-0.01908011920750141,
0.02555457316339016,
-0.24656186997890472,
-0.4571320712566376,
0.06937337666749954,
0.8308765292167664,
0.029696255922317505,
-0.0016858405433... | |
I'm trying to setup a bidirectional localConnection (LC) between two flash objects on the same web page. One object is AS2 and the other AS3.
1. I'm using one LC object to send and receive data on each swf. (This shouldn't matter, right? I tried using two objects, one for sending and one for receiving, but got the sam... | [
0.10054372996091843,
-0.5381689667701721,
0.4670239984989166,
0.20187558233737946,
-0.11176091432571411,
0.08717596530914307,
0.07989340275526047,
0.08894363045692444,
-0.27752798795700073,
-0.754410982131958,
-0.0968484953045845,
0.4514366388320923,
-0.48864248394966125,
0.017243081703782... | |
with the LC names (I checked, obviously)
Sometimes one or two messages go through and consequtive messages fail.
Any idea on what might cause it?
I'm aiming to create a many-to-one connection map so that many AS2 swfs could connect to the one AS3 swf. Will that be a problem?
I finally figured out what caused the pro... | [
-0.12286558747291565,
-0.4198673665523529,
0.1457543671131134,
0.04474787041544914,
-0.1657494604587555,
-0.14816813170909882,
0.44114336371421814,
-0.0289068091660738,
-0.5331999063491821,
-0.6849894523620605,
0.05402703955769539,
0.318643182516098,
-0.5872856974601746,
0.1773391664028167... | |
What the minimum basic setup required to begin developing a Firefox extension?
Step 1: Use the [Add-on Builder](https://addons.mozilla.org/en-US/developers/tools/builder) to generate all the necessary files.
Step 2: Extract the downloaded files into your development area.
Step 3: Create a text file in your profile's ... | [
0.5448414087295532,
-0.09240194410085678,
0.6090418696403503,
-0.22872108221054077,
0.45524030923843384,
-0.4341967701911926,
0.37759828567504883,
-0.6706640124320984,
-0.12106948345899582,
-0.5862643718719482,
-0.6000353693962097,
0.7124300003051758,
-0.539305567741394,
-0.228507712483406... | |
When reading about SQL Injection and XSS i was wondering if you guys have a single string that could be used to identify those vulnerabilities and others.
A string that could be thrown into a website database to black box check if that field is safe or not. (going to do a large test on a few inhouse tools)
Rough exam... | [
0.5669094324111938,
-0.005332094617187977,
-0.05601872131228447,
0.40874773263931274,
-0.20754529535770416,
-0.3728070557117462,
0.19876982271671295,
-0.1122635006904602,
-0.1393185555934906,
-0.4781368672847748,
-0.021581394597887993,
0.49727508425712585,
-0.40788376331329346,
-0.20197071... | |
I want to be able to change the status message for Live Messenger, but everything I've found only works for the music message (see [this screenshot](http://coldacid.net/images/screenshots/live-messenger-status-and-music-messages) to see the difference between the two).
It is possible to do this, as there are programs ... | [
0.4860623776912689,
-0.10696718841791153,
0.276223361492157,
0.05629013478755951,
0.0634913221001625,
-0.25926539301872253,
0.5324671864509583,
-0.12075837701559067,
-0.2625848948955536,
-0.924053966999054,
0.19807440042495728,
0.5484296083450317,
-0.21366481482982635,
-0.10544735938310623... | |
14.x versions that I'm working with.
There is no programmatic way of setting the Live Messenger status message that works with versions inclusive of Live Wave 3. | [
0.5903510451316833,
-0.12914635241031647,
0.4027821719646454,
-0.10657130926847458,
-0.33250442147254944,
-0.3838423490524292,
0.430451899766922,
0.2754916846752167,
-0.10365999490022659,
-0.7183877229690552,
-0.09615591168403625,
0.5065025687217712,
-0.5176247358322144,
-0.273178547620773... | |
### Are there differences between the amount of syscalls in the major \*NIX variants ?
### Which syscalls would be supported universally ?
Anything that is not a posix standard may be an additional system call, or it maybe additional library functionality above the system call layer. If your goal is to write portable ... | [
0.5741156339645386,
0.07626447081565857,
0.2951241731643677,
0.1877811700105667,
-0.16807352006435394,
-0.17896072566509247,
-0.05386841297149658,
-0.10728226602077484,
-0.38776397705078125,
-0.42166218161582947,
-0.1630447655916214,
0.5657898783683777,
-0.3337133526802063,
-0.400176614522... | |
interfaces you need to support, but whether you do that through calling into the kernel or jumping into a shared library is pretty much up to you.
Mac OS X does not even guarantee binary compatibility for system calls between releases, they consider them private interfaces between the system libraries and the OS. What... | [
0.22365255653858185,
0.04514945670962334,
0.29931941628456116,
0.3513348698616028,
-0.2939392030239105,
-0.12082155793905258,
0.13262112438678741,
0.10651341080665588,
-0.14465446770191193,
-0.7975894212722778,
0.14805163443088531,
0.6019091010093689,
-0.4638481140136719,
0.106802232563495... | |
OS releases.
That flexibility means a number of OSes implement system calls that are completely different from what they need to support posix, then deal with the differences in their libraries. For example, Linux's threading implementation is based around a system call called clone(), and they deal with much of the b... | [
0.3567811846733093,
-0.040029242634773254,
0.31802621483802795,
0.13282564282417297,
0.08661165088415146,
-0.32686203718185425,
-0.16725748777389526,
0.1781768798828125,
-0.3213907778263092,
-0.64557284116745,
-0.4753188490867615,
0.4529867470264435,
-0.39345404505729675,
0.185719266533851... | |
against the standard libraries on various Unixes you can get a generally uniform interface. | [
-0.05516475439071655,
-0.05787910148501396,
-0.000600612023845315,
0.2357187122106552,
-0.18184693157672882,
-0.3086053431034088,
-0.10556402802467346,
0.3350484371185303,
-0.24571353197097778,
-0.7221724987030029,
0.003710581222549081,
0.7958029508590698,
-0.30355578660964966,
-0.10620842... | |
Are there anyone with experiences/examples on releasing early/releasing often for commercial software? Does it work?
I was thinking of VMware where they have a lot of revisions release between each major version. And the installation experience was awful, sometimes they would break the existing VMs and other times the... | [
0.6147300004959106,
0.16830754280090332,
0.18531468510627747,
0.0459820032119751,
0.08228950947523117,
-0.30979087948799133,
0.05413801223039627,
0.1873663365840912,
-0.6104245781898499,
-0.4186231195926666,
0.061493802815675735,
0.753089427947998,
0.061132777482271194,
0.11923738569021225... | |
"upgraded" to get those bugs as well.
Do you have experience\example\suggestion to applying the release early/release often principle to commercial software?
I'm looking to apply it to one.
Kenny is right: it depends.
We work on Enterprise software, where a customer may run an internal 3+ month project to upgrade to... | [
0.6903482675552368,
0.20614761114120483,
0.20716510713100433,
0.07336191087961197,
0.13782872259616852,
-0.028925318270921707,
0.05362568795681,
0.016924528405070305,
-0.1716669648885727,
-0.5517178773880005,
-0.023555750027298927,
0.9380159378051758,
-0.01866007037460804,
-0.1083384901285... | |
went to see how to get it and discovered that Chrome had already updated itself. If there was any notification I missed it, and that is fine with me.
**The main question is how disruptive a new release is**. For example, if MS released new versions of Visual Studio every 3 months with a new .NET version, C runtime, et... | [
0.6747949719429016,
0.0754169225692749,
0.47201237082481384,
-0.037618886679410934,
-0.4058395028114319,
-0.506078839302063,
0.2572789788246155,
0.19955599308013916,
-0.5068293213844299,
-0.5757742524147034,
-0.08503846079111099,
0.7502807974815369,
-0.12902967631816864,
0.3072496354579925... | |
-- just make the download/install process as seamless as possible. | [
0.5489904284477234,
0.15774452686309814,
0.02337108924984932,
0.4861232042312622,
0.23427845537662506,
-0.4462875723838806,
0.23227830231189728,
0.4494689106941223,
0.2563915252685547,
-0.6312841773033142,
-0.30175307393074036,
0.7587941884994507,
0.19592492282390594,
-0.18261343240737915,... | |
I've seen (and used) on various projects this layout, with a group of fields followed by a group of properties:
```
private int MyIntField;
private string MyStringField;
public int MyInt {
get { return MyIntField; }
set { MyIntField = value; }
}
public string MyString {
get { return MyStringField; }... | [
0.03697860985994339,
-0.1728859692811966,
0.5568650364875793,
-0.11142482608556747,
0.20741477608680725,
0.15788309276103973,
-0.09807001799345016,
-0.19919772446155548,
0.02012266032397747,
-0.5285978317260742,
-0.10884923487901688,
0.6886416673660278,
-0.1650519222021103,
0.2331661283969... | |
MyIntField = value; }
}
private string MyStringField;
public string MyString {
get { return MyStringField; }
set { MyStringField = value; }
}
```
Is there a reason to consider one better than the other? I think most coding standards recommend Option #1, but sometimes it's handy having the field next to ... | [
0.15117588639259338,
-0.03142043575644493,
0.09389255940914154,
-0.047696493566036224,
0.09037808328866959,
-0.2141912877559662,
0.28710490465164185,
0.02178298868238926,
0.12738651037216187,
-0.5009151697158813,
-0.23626135289669037,
0.8014953136444092,
-0.24724723398685455,
-0.0622709840... | |
the methods/interfaces together, the private members....I think you get the point. | [
0.36022597551345825,
0.138353168964386,
-0.037704307585954666,
0.16742442548274994,
-0.13851511478424072,
-0.2020711451768875,
0.15927743911743164,
-0.013169686309993267,
-0.10191512107849121,
-0.5030542612075806,
0.12182126939296722,
0.5185075998306274,
0.04283248633146286,
0.004512212704... | |
I read somewhere in the Microsoft documentation that the content of the ASP.NET's **web.config is cached**. If that is true, **where** is it cached - in **memory or on disk**?
And a follow-up question: are there any performance considerations I have to make, if I have to access the web.config intensively?
Its cached i... | [
0.12099315226078033,
-0.027194611728191376,
0.24900583922863007,
0.2184997946023941,
-0.021425094455480576,
-0.2091987282037735,
0.04359641298651695,
0.016378792002797127,
-0.256291925907135,
-0.8924398422241211,
-0.17710453271865845,
0.6897886991500854,
0.04100116714835167,
0.001283249934... | |
implementation of the Section object (the object returned by GetSection). A `ConfigurationSection` may simply act as wrapper for a DOM node which it may read on every request for a property. OTH it could internaly cache the value and watch for changes.
My advice would be keep your code simple and just access the value... | [
0.1556852012872696,
-0.38371482491493225,
0.2519712746143341,
0.036001551896333694,
0.1277443766593933,
-0.08391324430704117,
0.3603488802909851,
-0.1890871226787567,
-0.3420090079307556,
-0.5259211659431458,
-0.10709605365991592,
0.5845824480056763,
-0.36065471172332764,
0.206962898373603... | |
After logging in using the Login control the browser loses the session. This only occurs in Internet Explorer 7. Has anyone else run into this problem? If so, do you know a work around?
I would suggest downloading a tool like [ieHTTPHeaders](http://www.blunck.se/iehttpheaders/download.html) to trace the request/respnon... | [
0.044503774493932724,
-0.0789996087551117,
0.6024644374847412,
-0.09753705561161041,
0.1017627939581871,
-0.5254095196723938,
0.7354773283004761,
0.37398189306259155,
-0.4686579704284668,
-0.8296908736228943,
-0.35557353496551514,
0.6684679985046387,
-0.4059421122074127,
0.0857925191521644... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.